1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

AAC encoder: don't apply MS on special bands

Change the condition for application of the M/S transform to match
that of the decoder. Namely, that no special coding books must be
in use in either channel. While the condition ought to be
equivalent to the current one when the invariant of is_mask is
kept, matching the decoder's condition is safer and easier to
maintain.
This commit is contained in:
Claudio Freire 2016-01-08 05:04:37 -03:00
parent 00d481b2c3
commit 509f168017

View File

@ -300,8 +300,8 @@ static void apply_mid_side_stereo(ChannelElement *cpe)
* ms_mask is set. * ms_mask is set.
*/ */
if (!cpe->ms_mask[w*16 + g] || cpe->is_mask[w*16 + g] if (!cpe->ms_mask[w*16 + g] || cpe->is_mask[w*16 + g]
|| cpe->ch[0].band_type[w*16 + g] == NOISE_BT || cpe->ch[0].band_type[w*16 + g] >= NOISE_BT
|| cpe->ch[1].band_type[w*16 + g] == NOISE_BT) { || cpe->ch[1].band_type[w*16 + g] >= NOISE_BT) {
start += ics->swb_sizes[g]; start += ics->swb_sizes[g];
continue; continue;
} }