diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2014-10-08 20:23:40 +0200 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-10-08 20:39:37 +0200 |
commit | be695ee389724d713e1b8a61ef899fe1795193ce (patch) | |
tree | ce41806c4e22f64d23593358a013a479487abec6 /libavformat/matroskadec.c | |
parent | 33db99548b99ebecb82b32cb82b4e49e3ecd4794 (diff) | |
download | ffmpeg-be695ee389724d713e1b8a61ef899fe1795193ce.tar.gz |
avformat/matroskadec: do not trust the default duration to be the real 1/timebase if its less than 5fps
Fixes Ticket3980
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavformat/matroskadec.c')
-rw-r--r-- | libavformat/matroskadec.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/matroskadec.c b/libavformat/matroskadec.c index 0e405c7387..105e1f4b20 100644 --- a/libavformat/matroskadec.c +++ b/libavformat/matroskadec.c @@ -1920,7 +1920,8 @@ static int matroska_parse_tracks(AVFormatContext *s) av_reduce(&st->avg_frame_rate.num, &st->avg_frame_rate.den, 1000000000, track->default_duration, 30000); #if FF_API_R_FRAME_RATE - if (st->avg_frame_rate.num < st->avg_frame_rate.den * 1000L) + if ( st->avg_frame_rate.num < st->avg_frame_rate.den * 1000L + && st->avg_frame_rate.num > st->avg_frame_rate.den * 5L) st->r_frame_rate = st->avg_frame_rate; #endif } |