Lines Matching defs:pkt
258 static int sga_video_packet(AVFormatContext *s, AVPacket *pkt)
289 ret = av_new_packet(pkt, sga->payload_size + 4);
292 memcpy(pkt->data, sga->sector, sga->payload_size + 4);
296 pkt->stream_index = sga->video_stream_index;
297 pkt->duration = 1;
298 pkt->pos = sga->pkt_pos;
299 pkt->flags |= sga->flags;
304 av_log(s, AV_LOG_DEBUG, "VIDEO PACKET: %d:%016"PRIX64" i:%X\n", pkt->size, AV_RB64(sga->sector), sga->idx);
309 static int sga_audio_packet(AVFormatContext *s, AVPacket *pkt)
335 ret = av_new_packet(pkt, sga->payload_size - 8);
338 memcpy(pkt->data, sga->sector + 12, sga->payload_size - 8);
342 pkt->stream_index = sga->audio_stream_index;
343 pkt->duration = pkt->size;
344 pkt->pos = sga->pkt_pos;
345 pkt->flags |= sga->flags;
350 av_log(s, AV_LOG_DEBUG, "AUDIO PACKET: %d:%016"PRIX64" i:%X\n", pkt->size, AV_RB64(sga->sector), sga->idx);
355 static int sga_packet(AVFormatContext *s, AVPacket *pkt)
368 ret = sga_video_packet(s, pkt);
373 ret = sga_audio_packet(s, pkt);
387 static int try_packet(AVFormatContext *s, AVPacket *pkt)
395 ret = sga_packet(s, pkt);
404 static int sga_read_packet(AVFormatContext *s, AVPacket *pkt)
451 ret = try_packet(s, pkt);