A fix to the RE0 Audio fix (Hopefully this fixes it once and for all.
git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@3200 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
parent
9a25c5f70b
commit
b8fe20e84e
|
@ -30,6 +30,8 @@ SConfig::SConfig()
|
||||||
{
|
{
|
||||||
// Make sure we have log manager
|
// Make sure we have log manager
|
||||||
LoadSettings();
|
LoadSettings();
|
||||||
|
//Mkae sure we load settings
|
||||||
|
LoadSettingsHLE();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -247,4 +249,13 @@ void SConfig::LoadSettings()
|
||||||
ini.Get("Core", "WiiMote1Plugin", &m_LocalCoreStartupParameter.m_strWiimotePlugin[0], m_DefaultWiiMotePlugin.c_str());
|
ini.Get("Core", "WiiMote1Plugin", &m_LocalCoreStartupParameter.m_strWiimotePlugin[0], m_DefaultWiiMotePlugin.c_str());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
void SConfig::LoadSettingsHLE()
|
||||||
|
{
|
||||||
|
IniFile ini;
|
||||||
|
//
|
||||||
|
ini.Load(FULL_CONFIG_DIR "DSP.ini");
|
||||||
|
ini.Get("Config", "EnableRE0AudioFix", &m_EnableRE0Fix, false); // RE0 Hack
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
|
@ -40,6 +40,9 @@ enum INTERFACE_LANGUAGE
|
||||||
|
|
||||||
struct SConfig
|
struct SConfig
|
||||||
{
|
{
|
||||||
|
//DSP HLE Audio fix
|
||||||
|
bool m_EnableRE0Fix;
|
||||||
|
|
||||||
// hard coded default plugins ...
|
// hard coded default plugins ...
|
||||||
std::string m_DefaultGFXPlugin;
|
std::string m_DefaultGFXPlugin;
|
||||||
std::string m_DefaultDSPPlugin;
|
std::string m_DefaultDSPPlugin;
|
||||||
|
@ -80,6 +83,9 @@ struct SConfig
|
||||||
// load settings
|
// load settings
|
||||||
void LoadSettings();
|
void LoadSettings();
|
||||||
|
|
||||||
|
//Special load settings
|
||||||
|
void LoadSettingsHLE();
|
||||||
|
|
||||||
/* Return the permanent and somewhat globally used instance of this struct
|
/* Return the permanent and somewhat globally used instance of this struct
|
||||||
there is also a Core::GetStartupParameter() instance of it with almost
|
there is also a Core::GetStartupParameter() instance of it with almost
|
||||||
the same values */
|
the same values */
|
||||||
|
|
|
@ -26,6 +26,7 @@
|
||||||
#include "../../PatchEngine.h"
|
#include "../../PatchEngine.h"
|
||||||
#include "../../CoreTiming.h"
|
#include "../../CoreTiming.h"
|
||||||
#include "../../Debugger/Debugger_BreakPoints.h"
|
#include "../../Debugger/Debugger_BreakPoints.h"
|
||||||
|
#include "../../ConfigManager.h"
|
||||||
#include "../PowerPC.h"
|
#include "../PowerPC.h"
|
||||||
#include "../Profiler.h"
|
#include "../Profiler.h"
|
||||||
#include "../PPCTables.h"
|
#include "../PPCTables.h"
|
||||||
|
@ -160,6 +161,7 @@ ps_adds1
|
||||||
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
Jit64 jit;
|
Jit64 jit;
|
||||||
|
|
||||||
int CODE_SIZE = 1024*1024*16;
|
int CODE_SIZE = 1024*1024*16;
|
||||||
|
@ -232,6 +234,8 @@ namespace CPUCompare
|
||||||
// This is only called by Default() in this file. It will execute an instruction with the interpreter functions.
|
// This is only called by Default() in this file. It will execute an instruction with the interpreter functions.
|
||||||
void Jit64::WriteCallInterpreter(UGeckoInstruction inst)
|
void Jit64::WriteCallInterpreter(UGeckoInstruction inst)
|
||||||
{
|
{
|
||||||
|
|
||||||
|
|
||||||
gpr.Flush(FLUSH_ALL);
|
gpr.Flush(FLUSH_ALL);
|
||||||
fpr.Flush(FLUSH_ALL);
|
fpr.Flush(FLUSH_ALL);
|
||||||
if (js.isLastInstruction)
|
if (js.isLastInstruction)
|
||||||
|
@ -241,6 +245,14 @@ namespace CPUCompare
|
||||||
}
|
}
|
||||||
Interpreter::_interpreterInstruction instr = GetInterpreterOp(inst);
|
Interpreter::_interpreterInstruction instr = GetInterpreterOp(inst);
|
||||||
ABI_CallFunctionC((void*)instr, inst.hex);
|
ABI_CallFunctionC((void*)instr, inst.hex);
|
||||||
|
|
||||||
|
if (js.isLastInstruction && SConfig::GetInstance().m_EnableRE0Fix )
|
||||||
|
{
|
||||||
|
|
||||||
|
SConfig::GetInstance().LoadSettingsHLE();//Make sure the settings are up to date
|
||||||
|
MOV(32, R(EAX), M(&NPC));
|
||||||
|
WriteRfiExitDestInEAX();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Jit64::unknown_instruction(UGeckoInstruction inst)
|
void Jit64::unknown_instruction(UGeckoInstruction inst)
|
||||||
|
|
Loading…
Reference in New Issue