New zelda ucode voice case

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3609 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
XTra.KrazzY 2009-06-29 22:03:17 +00:00
parent 499ffa33c2
commit 5e65e94c4b
1 changed files with 9 additions and 0 deletions

View File

@ -278,6 +278,11 @@ void CUCode_Zelda::MixAddVoice(ZeldaVoicePB &PB, s32* _LeftBuffer, s32* _RightBu
{ {
switch (PB.Format) switch (PB.Format)
{ {
case 0x0000: // Silences sound and stops all looping sounds
for (int i = 0; i < _Size; i++)
_LeftBuffer[i] = _RightBuffer[i] = 0;
return;
case 0x0005: // AFC / unknown case 0x0005: // AFC / unknown
case 0x0021: // AFC / ADPCM??? case 0x0021: // AFC / ADPCM???
case 0x0009: // AFC / ADPCM case 0x0009: // AFC / ADPCM
@ -287,6 +292,10 @@ void CUCode_Zelda::MixAddVoice(ZeldaVoicePB &PB, s32* _LeftBuffer, s32* _RightBu
case 0x0010: // PCM16 case 0x0010: // PCM16
MixAddVoice_PCM16(PB, m_TempBuffer, _Size); MixAddVoice_PCM16(PB, m_TempBuffer, _Size);
break; break;
default:
PanicAlert("Unknown MixAddVoice format in zelda %04x", PB.Format);
break;
} }
PB.NeedsReset = 0; PB.NeedsReset = 0;