[FFmpeg-devel] [PATCH] avcodec/flacenc: fix calculation of bits required in case of custom sample rate

Rostislav Pehlivanov atomnuker at gmail.com
Sun Jan 24 21:41:32 CET 2016


On 24 January 2016 at 19:53, Paul B Mahol <onemda at gmail.com> wrote:

> Hi,
>
> patch attached.
>

LGTM

sr_code will be 12 in case the samplerate is below 255000 (so the header
will be +1 bytes long) and 14 (> 12 so the header will be +2 bytes long) if
it's above. The previous code assumed the first part in the brackets would
be 1 so it miscalculated the header size. So lgtm.


More information about the ffmpeg-devel mailing list