[FFmpeg-devel] Ratecontrol problem

Michael Niedermayer michaelni at gmx.at
Tue Nov 20 21:11:44 CET 2012


On Tue, Nov 20, 2012 at 04:23:25PM +0000, Joseph Artsimovich wrote:
> Hi,
> 
> I found another problem with ratecontrol. Encoding a single IMX30
> frame like this:
> 
> ffmpeg -i uncompressable.png -y -vcodec mpeg2video -r 25 -pix_fmt
> yuv422p -minrate 30000k -maxrate 30000k -b:v 30000k -intra -flags
> +ildct+low_delay -dc 10 -intra_vlc 1 -non_linear_quant 1 -ps 1 -qmin
> 1 -qmax 12 -top 1 -bufsize 1200000 -rc_init_occupancy 1200000
> -rc_buf_aggressivity 0.25 -vtag mx3p -an out.mov
> 
> produces a "rc buffer underflow". I uploaded the image I was
> encoding here (it wont reproduce with just any image):
> http://postimage.org/image/rzthpgjvr/
> 
> The settings I used correspond to the ones from FFMpeg howto, except
> I raised qmax to the maximum possible value non_linear_quant
> supports. Yet, it fails to fit ratecontrol restrictions even then.
> That's actually a big deal when working with MXFs.
> 
> Using git bisect I found the offending commit:
> ------------------------
> commit ce7876cbf4cd3e6f07a36e2fe1e28ca825dd5141
> Author: Michael Niedermayer <michaelni at gmx.at>
> Date:   Tue Sep 11 17:38:31 2012 +0200
> 
>     ratecontrol: Dynamically choose a default for rc_max_available_vbv_use
> 
>     This improves handling of small buffer sizes
> ------------------------
> 
> Adding "-rc_max_vbv_use 1" fixed the problem, yet I tend to think
> the commit in question didn't intend to change pre-existing
> behaviour when that option isn't specified.

should be fixed

thanks for the detailed report

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

If a bugfix only changes things apparently unrelated to the bug with no
further explanation, that is a good sign that the bugfix is wrong.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20121120/d397021f/attachment.asc>


More information about the ffmpeg-devel mailing list