ffmpeg-libav-tutorial
ffmpeg-libav-tutorial copied to clipboard
rc_max_rate bigger than rc_min_rate
In trascoding example there are these lines: video_avcc->rc_max_rate = 2 * 1000 * 1000; video_avcc->rc_min_rate = 2.5 * 1000 * 1000;
Which are wrong since the max rate is less than the minimal rate.
thanks for pointing out
Well in fact I would like to mention that rc_min_rate is not used by libx264.c nor libx265.c in FFMPEG source code so probably this value should be removed since it does nothing.
https://github.com/libav/libav/blob/master/libavcodec/libx264.c rc_max_rate is used to set vbv_max_bitrat in libx264 internal
rc_min_rate seems to only be used in nvenc codec: https://github.com/libav/libav/blob/c4642788e83b0858bca449f9b6e71ddb015dfa5d/libavcodec/nvenc.c#L1016
(and 2 more random codecs)