Mercurial > libavformat.hg
changeset 469:6a4cc19e8d9b libavformat
exporting keyframe flags, fixes keyframe stuff with streamcopy
author | michael |
---|---|
date | Sat, 29 May 2004 12:01:28 +0000 |
parents | 60f897e8dd2d |
children | 334e08488ad1 |
files | avidec.c |
diffstat | 1 files changed, 9 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/avidec.c Sat May 29 02:06:32 2004 +0000 +++ b/avidec.c Sat May 29 12:01:28 2004 +0000 @@ -52,6 +52,8 @@ DVDemuxContext* dv_demux; } AVIContext; +static int avi_load_index(AVFormatContext *s); + #ifdef DEBUG static void print_tag(const char *str, unsigned int tag, int size) { @@ -338,6 +340,10 @@ return -1; } + assert(!avi->index_loaded); + avi_load_index(s); + avi->index_loaded = 1; + return 0; } @@ -422,9 +428,10 @@ ast = st->priv_data; /* XXX: how to handle B frames in avi ? */ - pkt->pts = ast->frame_offset; + pkt->dts = ast->frame_offset; +// pkt->dts += ast->start; if(ast->sample_size) - pkt->pts /= ast->sample_size; + pkt->dts /= ast->sample_size; //printf("%Ld %d %d %d %d\n", pkt->pts, ast->frame_offset, ast->scale, AV_TIME_BASE, ast->rate); pkt->stream_index = n; /* FIXME: We really should read index for that */