diff options
author | Jan Ekström <jeebjp@gmail.com> | 2021-04-07 21:17:04 +0300 |
---|---|---|
committer | Jan Ekström <jeebjp@gmail.com> | 2021-04-11 13:53:05 +0300 |
commit | 5945288818b98682884888e3800893b2f2ac7507 (patch) | |
tree | 711c476218ac4403fe5676bbe7fa3abdc83e948e | |
parent | ef16dcc6a9240644d8e06528c19710783b7c6adf (diff) | |
download | ffmpeg-5945288818b98682884888e3800893b2f2ac7507.tar.gz |
avformat/img2dec: set r_frame_rate in addition to avg_frame_rate
Apparently for various image sequences libavformat/utils.c can
calculate rather fancy r_frame_rate values, such as `186/1921`,
and since ffmpeg.c utilizes r_frame_rate for the filter chain
time base, this can quite deteriorate the output frame timing - even
though the user has requested the image sequence to be interpreted
at a specific, constant frame rate.
-rw-r--r-- | libavformat/img2dec.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavformat/img2dec.c b/libavformat/img2dec.c index be7149bb2f..7b03cb2af1 100644 --- a/libavformat/img2dec.c +++ b/libavformat/img2dec.c @@ -222,7 +222,7 @@ int ff_img_read_header(AVFormatContext *s1) avpriv_set_pts_info(st, 64, 1, 1); else { avpriv_set_pts_info(st, 64, s->framerate.den, s->framerate.num); - st->avg_frame_rate = s->framerate; + st->avg_frame_rate = st->r_frame_rate = s->framerate; } if (s->width && s->height) { |