summaryrefslogtreecommitdiff
path: root/libavcodec/ac3dec.c
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-01-21 14:55:48 +0100
committerMichael Niedermayer <michaelni@gmx.at>2013-01-21 14:55:48 +0100
commitacc0c0190bd6144d921397d53e928532a8d86de0 (patch)
treef7296da32f37597be3fd11bd4ac9fddf6037743a /libavcodec/ac3dec.c
parentfbdb0313f53f84f5a8a5a23ad1880bf7ef4dcc5f (diff)
parentf53490cc0c809975f8238d5a9edbd26f83bd2f84 (diff)
Merge commit 'f53490cc0c809975f8238d5a9edbd26f83bd2f84'
* commit 'f53490cc0c809975f8238d5a9edbd26f83bd2f84': rtpdec/srtp: Handle CSRC fields being present rtpdec: Check the return value from av_new_packet ac3dec: fix non-optimal dithering of zero bit mantissas Conflicts: libavcodec/ac3dec.c libavformat/rtpdec.c Merged-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/ac3dec.c')
-rw-r--r--libavcodec/ac3dec.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/libavcodec/ac3dec.c b/libavcodec/ac3dec.c
index ee8b9701b1..7adcb5c0da 100644
--- a/libavcodec/ac3dec.c
+++ b/libavcodec/ac3dec.c
@@ -442,6 +442,7 @@ static void ac3_decode_transform_coeffs_ch(AC3DecodeContext *s, int ch_index, ma
int mantissa;
switch (bap) {
case 0:
+ /* random noise with approximate range of -0.707 to 0.707 */
if (dither)
mantissa = (((av_lfg_get(&s->dith_state)>>8)*181)>>8) - 5931008;
else