Browse Source

Revert r20050, which caused decoding errors with at least one valid AC-3 file.

Originally committed as revision 20437 to svn://svn.ffmpeg.org/ffmpeg/trunk
tags/v0.6
Justin Ruggles 15 years ago
parent
commit
94593c9b52
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      libavcodec/ac3.c

+ 1
- 1
libavcodec/ac3.c View File

@@ -228,7 +228,7 @@ void ff_ac3_bit_alloc_calc_bap(int16_t *mask, int16_t *psd, int start, int end,
band = bin_to_band_tab[start]; band = bin_to_band_tab[start];
do { do {
int m = (FFMAX(mask[band] - snr_offset - floor, 0) & 0x1FE0) + floor; int m = (FFMAX(mask[band] - snr_offset - floor, 0) & 0x1FE0) + floor;
int band_end = FFMIN(bin + ff_ac3_critical_band_size_tab[band], end);
int band_end = FFMIN(band_start_tab[band] + ff_ac3_critical_band_size_tab[band], end);
for (; bin < band_end; bin++) { for (; bin < band_end; bin++) {
int address = av_clip((psd[bin] - m) >> 5, 0, 63); int address = av_clip((psd[bin] - m) >> 5, 0, 63);
bap[bin] = bap_tab[address]; bap[bin] = bap_tab[address];


Loading…
Cancel
Save