OSDN Git Service

avcodec/dcaenc: Do not abort process in case of bitrate deficit
authorDaniil Cherednik <dan.cherednik@gmail.com>
Thu, 11 May 2017 21:12:07 +0000 (21:12 +0000)
committerRostislav Pehlivanov <atomnuker@gmail.com>
Tue, 16 May 2017 10:22:07 +0000 (11:22 +0100)
commit9c4e69b8eac8955ce65df2fba2addaeefe81784f
treecba18e4b80e98999dda396d3c57e5a0b9d07d065
parent8e7e74df93d18c903164a67c861a428bd4244cb1
avcodec/dcaenc: Do not abort process in case of bitrate deficit

Old behaviour - abort if at least one subband has 1bit quantizer
and consumed_bits still greater than frame_bits size. It was
a bit strange - we still could reduce bits consumption by reducing
SNR for other subbands. Same strange logic with upper threshold -
stop bits allocation if at least one subband reach 26bits.

New behaviour - if consumed_bits greater than frame_bits and all
subbands has 1 bit quantizer we restart bits allocation and allow
zero subbands.
libavcodec/dcaenc.c