]> git.nihav.org Git - nihav.git/commitdiff
aac: fix intensity stereo direction
authorKostya Shishkov <kostya.shishkov@gmail.com>
Wed, 19 Jul 2023 16:00:35 +0000 (18:00 +0200)
committerKostya Shishkov <kostya.shishkov@gmail.com>
Wed, 19 Jul 2023 16:00:35 +0000 (18:00 +0200)
nihav-mpeg/src/codecs/aac/mod.rs

index 65148534a0d929ca517c71cf4650cf9346ad6dcb..ea262b9dfe330ab5e2190831421fb609fcda4018 100644 (file)
@@ -348,7 +348,7 @@ impl ChannelPair {
                         let invert = (self.ms_mask_present == 1) && self.ms_used[g][sfb];
                         let dir = self.ics[1].get_intensity_dir(g, sfb) ^ invert;
                         let scale = 0.5f32.powf(0.25 * (f32::from(self.ics[1].scales[g][sfb]) + f32::from(INTENSITY_SCALE_MIN)));
-                        if !dir {
+                        if dir {
                             for i in start..end {
                                 self.ics[1].coeffs[i] = scale * self.ics[0].coeffs[i];
                             }