Lines Matching defs:pkt
84 avs_read_video_packet(AVFormatContext * s, AVPacket * pkt,
91 ret = av_new_packet(pkt, size + palette_size);
96 pkt->data[0] = 0x00;
97 pkt->data[1] = 0x03;
98 pkt->data[2] = palette_size & 0xFF;
99 pkt->data[3] = (palette_size >> 8) & 0xFF;
100 memcpy(pkt->data + 4, palette, palette_size - 4);
103 pkt->data[palette_size + 0] = sub_type;
104 pkt->data[palette_size + 1] = type;
105 pkt->data[palette_size + 2] = size & 0xFF;
106 pkt->data[palette_size + 3] = (size >> 8) & 0xFF;
107 ret = get_buffer(s->pb, pkt->data + palette_size + 4, size - 4) + 4;
109 av_free_packet(pkt);
113 pkt->size = ret + palette_size;
114 pkt->stream_index = avs->st_video->index;
116 pkt->flags |= AV_PKT_FLAG_KEY;
121 static int avs_read_audio_packet(AVFormatContext * s, AVPacket * pkt)
127 ret = voc_get_packet(s, pkt, avs->st_audio, avs->remaining_audio_size);
136 pkt->stream_index = avs->st_audio->index;
137 pkt->flags |= AV_PKT_FLAG_KEY;
142 static int avs_read_packet(AVFormatContext * s, AVPacket * pkt)
152 if (avs_read_audio_packet(s, pkt) > 0)
190 return avs_read_video_packet(s, pkt, type, sub_type, size,
201 size = avs_read_audio_packet(s, pkt);