From 2a95dadb7339659710967db406c2fa2f5340962b Mon Sep 17 00:00:00 2001 From: ramapcsx2 Date: Thu, 2 Jun 2011 08:12:40 +0000 Subject: [PATCH] SPU2-X: Changes to reflect results of tests on my PS2. git-svn-id: http://pcsx2.googlecode.com/svn/trunk@4700 96395faa-99c1-11dd-bbfe-3dabce05a288 --- plugins/spu2-x/src/spu2sys.cpp | 65 +++++++++++++++++++++++----------- 1 file changed, 44 insertions(+), 21 deletions(-) diff --git a/plugins/spu2-x/src/spu2sys.cpp b/plugins/spu2-x/src/spu2sys.cpp index dcd12cbccc..574a3fae2a 100644 --- a/plugins/spu2-x/src/spu2sys.cpp +++ b/plugins/spu2-x/src/spu2sys.cpp @@ -123,14 +123,14 @@ void V_Core::Init( int index ) Regs.ATTR = 0; ExtVol = V_VolumeLR::Max; InpVol = V_VolumeLR::Max; - FxVol = V_VolumeLR::Max; + FxVol = V_VolumeLR(0); - MasterVol = V_VolumeSlideLR::Max; + MasterVol = V_VolumeSlideLR(0,0); memset( &DryGate, -1, sizeof(DryGate) ); memset( &WetGate, -1, sizeof(WetGate) ); - Regs.MMIX = 0xFFCF; + Regs.MMIX = c ? 0xF3C : 0xF30; // PS2 confirmed (f3c and f30 after BIOS ran, ffc and ff0 after sdinit) Regs.VMIXL = 0xFFFFFF; Regs.VMIXR = 0xFFFFFF; Regs.VMIXEL = 0xFFFFFF; @@ -138,9 +138,9 @@ void V_Core::Init( int index ) EffectsStartA = c ? 0xEFFF8 : 0xFFFF8; EffectsEndA = c ? 0xEFFFF : 0xFFFFF; - FxEnable = 0; - IRQA = 0xFFFFF; - IRQEnable = 0; + FxEnable = 0; // Uninitialized it's 0 for both cores. Resetting libs however may set this to 0 or 1. + IRQA = 0xFFFFF; //0x40505E9C : 0x3220EAA4; // << Actual PS2 values, so this is uninitialized. + IRQEnable = 0; // PS2 confirmed for( uint v=0; v>vc) & 1) ) continue; Cores[core].Voices[vc].ADSR.Releasing = true; - //if(MsgKeyOnOff()) ConLog("* SPU2-X: KeyOff: Core %d; Voice %d.\n",core,vc); + if(MsgKeyOnOff()) ConLog("* SPU2-X: KeyOff: Core %d; Voice %d.\n",core,vc); } }