Fixed NullSound hanging on movies. Compared to DSound, it's now slower on movies but faster in menus

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@2183 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
XTra.KrazzY
2009-02-09 19:50:06 +00:00
parent 59a8fd4848
commit 09c8368180
8 changed files with 52 additions and 38 deletions

View File

@ -68,13 +68,7 @@ void Mixer(short *buffer, int numSamples, int bits, int rate, int channels)
g_dspInitialize.pGetAudioStreaming(buffer, numSamples);
}
//if this was called directly from the HLE, and not by timeout
if (g_Config.m_EnableHLEAudio && mixer_HLEready)
{
IUCode* pUCode = CDSPHandler::GetInstance().GetUCode();
if (pUCode != NULL)
pUCode->MixAdd(buffer, numSamples);
}
Mixer_MixUCode(buffer, numSamples, bits, rate, channels);
push_sync.Enter();
int count = 0;
@ -96,6 +90,17 @@ void Mixer(short *buffer, int numSamples, int bits, int rate, int channels)
push_sync.Leave();
}
void Mixer_MixUCode(short *buffer, int numSamples, int bits, int rate,
int channels) {
//if this was called directly from the HLE, and not by timeout
if (g_Config.m_EnableHLEAudio && mixer_HLEready)
{
IUCode* pUCode = CDSPHandler::GetInstance().GetUCode();
if (pUCode != NULL)
pUCode->MixAdd(buffer, numSamples);
}
}
void Mixer_PushSamples(short *buffer, int num_stereo_samples, int sample_rate) {
// static FILE *f;
// if (!f)