Browse Source

avcodec/ac3enc: Fix invalid shift

Fixes the FATE-tests unknown_layout-ac3, ac3-fixed-encode, ac3-encode
and eac3-encode. It furthermore fixes the ac3-encoder bugs mentioned in
tickets #7994, #8144 and #8159.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit 2f289ec914)
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
tags/n3.4.8
Andreas Rheinhardt 5 years ago
parent
commit
d4824eec3b
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      libavcodec/ac3enc.c

+ 1
- 1
libavcodec/ac3enc.c View File

@@ -1065,7 +1065,7 @@ static int bit_alloc(AC3EncodeContext *s, int snr_offset)
{
int blk, ch;

snr_offset = (snr_offset - 240) << 2;
snr_offset = (snr_offset - 240) * 4;

reset_block_bap(s);
for (blk = 0; blk < s->num_blocks; blk++) {


Loading…
Cancel
Save