mirror of https://github.com/PCSX2/pcsx2.git
SPU2Ghz: Fixed a problem in ADSR handling as suggested by gigaherz.
git-svn-id: http://pcsx2-playground.googlecode.com/svn/trunk@284 a6443dda-0b58-4228-96e9-037be469359c
This commit is contained in:
parent
5d6c89f1e2
commit
3d4583dcbb
|
@ -394,7 +394,7 @@ static void __forceinline CalculateADSR( V_Voice& vc )
|
|||
{
|
||||
env.Value -= PsxRates[(env.Sr^0x7f)-0xf+32];
|
||||
}
|
||||
if( env.Value < 0 )
|
||||
if( env.Value <= 0 )
|
||||
{
|
||||
env.Value = 0;
|
||||
env.Phase++;
|
||||
|
@ -447,7 +447,7 @@ static void __forceinline CalculateADSR( V_Voice& vc )
|
|||
env.Value-=PsxRates[((env.Rr^0x1f)<<2)-0xc+32];
|
||||
}
|
||||
|
||||
if( env.Value < 0 )
|
||||
if( env.Value <= 0 )
|
||||
{
|
||||
env.Value=0;
|
||||
env.Phase++;
|
||||
|
|
Loading…
Reference in New Issue