diff options
| author | Pierre Bourdon <delroth@gmail.com> | 2012-11-13 09:37:44 +0100 |
|---|---|---|
| committer | Pierre Bourdon <delroth@gmail.com> | 2012-11-13 09:37:44 +0100 |
| commit | 16060290c2dc3cac5c1cb4643d460bb778cc121d (patch) | |
| tree | 4613a1fc24923aa65eb101c1472def9e9ec553cb /Source/Core | |
| parent | 8eb6f9002e2663eababd0ade685e9f8107531cd2 (diff) | |
Fix missing notes in musics with DSPHLE.
Tales of Symphonia and Skies of Arcadia Legends now have working musics with
DSPHLE. Some other games with the same symptoms (missing instruments) should
probably be fixed by that change too.
Diffstat (limited to 'Source/Core')
| -rw-r--r-- | Source/Core/Core/Src/HW/DSPHLE/UCodes/UCode_AX.cpp | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/Source/Core/Core/Src/HW/DSPHLE/UCodes/UCode_AX.cpp b/Source/Core/Core/Src/HW/DSPHLE/UCodes/UCode_AX.cpp index da4b10f34e..c63929fe8f 100644 --- a/Source/Core/Core/Src/HW/DSPHLE/UCodes/UCode_AX.cpp +++ b/Source/Core/Core/Src/HW/DSPHLE/UCodes/UCode_AX.cpp @@ -172,8 +172,6 @@ void CUCode_AX::MixAdd(short* _pBuffer, int _iSize) if (!ReadPB(blockAddr, PB)) break; - ProcessUpdates(PB); - if (m_CRC != 0x3389a79e) VoiceHacks(PB); @@ -335,6 +333,24 @@ bool CUCode_AX::AXTask(u32& _uMail) PBaddr[numPBaddr] = HLEMemory_Read_U32(uAddress); numPBaddr++; + // HACK: process updates right now instead of waiting until + // Premix is called. Some games using sequenced music (Tales of + // Symphonia for example) thought PBs were unused because we + // were too slow to update them and set them as running. This + // happens because Premix is basically completely desync-ed + // from the emulation core (it's running in the audio thread). + // Fixing this would require rewriting most of the AX HLE. + u32 block_addr = uAddress; + AXPB pb; + while (block_addr) + { + if (!ReadPB(block_addr, pb)) + break; + ProcessUpdates(pb); + WritePB(block_addr, pb); + block_addr = (pb.next_pb_hi << 16) | pb.next_pb_lo; + } + m_addressPBs = HLEMemory_Read_U32(uAddress); // left in for now uAddress += 4; soundStream->GetMixer()->SetHLEReady(true); |
