[FFmpeg-cvslog] r23225 - in branches/0.6: . libavformat/matroskadec.c

siretart subversion
Fri May 21 22:13:35 CEST 2010


Author: siretart
Date: Fri May 21 22:13:34 2010
New Revision: 23225

Log:
set avg frame rate in mkv demuxer

backport r23152 by bcoudurier

Modified:
   branches/0.6/   (props changed)
   branches/0.6/libavformat/matroskadec.c

Modified: branches/0.6/libavformat/matroskadec.c
==============================================================================
--- branches/0.6/libavformat/matroskadec.c	Fri May 21 20:49:32 2010	(r23224)
+++ branches/0.6/libavformat/matroskadec.c	Fri May 21 22:13:34 2010	(r23225)
@@ -1390,6 +1390,8 @@ static int matroska_read_header(AVFormat
                       255);
             if (st->codec->codec_id != CODEC_ID_H264)
             st->need_parsing = AVSTREAM_PARSE_HEADERS;
+            if (track->default_duration)
+                st->avg_frame_rate = av_d2q(1000000000.0/track->default_duration, INT_MAX);
         } else if (track->type == MATROSKA_TRACK_TYPE_AUDIO) {
             st->codec->codec_type = AVMEDIA_TYPE_AUDIO;
             st->codec->sample_rate = track->audio.out_samplerate;



More information about the ffmpeg-cvslog mailing list