> >That's right. therefore in FAAC you will see this:
> >if ((nb[0][b] <= 1.58*nb[1][b])||(nb[1][b] <= 1.58*nb[0][b]))
> >and in LAME:
> >if ((ratio[0][b] >= 1.58*ratio[1][b])||(ratio[1][b] >= 1.58*ratio[0][b]))
> >
> >Or the other way around, I don't have access to my source code where I am
> now.
> >Also I think that LAME is doing these calculations with the final ratios,
> >while I in FAAC use the nb values (can't remember how they were called in
> >LAME, sorry).
> >The beta source code is available on the developers page, I hope you can find
> >them, it will make this a lot clearer.
> >
> >Bye, Menno
>
> Sorry, that was not entirely the reason. Basically the values are used in a
> whole different way, than in LAME. Just take a look at psy_step11andahalf().
>
> Menno
>
Hi Menno,
I took a look at psy_step11andahalf() and couldn't understand the
reasoning behind it. Maybe you could explain some?
I dont have the AAC ISO docs, so I'm just using the Johnson and
Ferreira reference. In that paper, the MLD correction is used to
compensate for stereo demasking, but only at low frequencies. The MLD
seems to be constructed so that at high frequencies, the maskings in
either channel will use the maximum over both channels, but at low
frequencies masking in one channel will only effect the other channel
up the the level of the MLD.
Thus at low frequencies, a signal in the mid channel will have less
masking on the side channel. Under this theory, MLD
must be in increasing function of frequency.
However, looking at this again and comparing with your formulas,
I think there is a mistake in LAME's implementation:
The comparison of mid and side maskings should be done with the true
maskings, not the masking/energy ratios. I will try to fix this
today.
Mark
the calculation should be done
It looked like both the switch to use the "MLD" correction, and
the correction are used in the opposite sense as they are in LAME.
In LAME,
--
MP3 ENCODER mailing list ( http://geek.rcc.se/mp3encoder/ )