Add rsp audio setting to Game Settings

This commit is contained in:
zilmar 2012-10-25 19:34:25 +11:00
parent bc746f5264
commit 22af031f01
2 changed files with 6 additions and 0 deletions

View File

@ -13,6 +13,7 @@ bool CGameSettings::m_bFixedAudio;
bool CGameSettings::m_bSyncToAudio;
bool CGameSettings::m_bFastSP;
bool CGameSettings::m_b32Bit;
bool CGameSettings::m_RspAudioSignal;
CGameSettings::CGameSettings()
{
@ -30,6 +31,7 @@ CGameSettings::CGameSettings()
_Settings->RegisterChangeCB(Game_SyncViaAudio,this,(CSettings::SettingChangedFunc)StaticRefreshSettings);
_Settings->RegisterChangeCB(Game_32Bit,this,(CSettings::SettingChangedFunc)StaticRefreshSettings);
_Settings->RegisterChangeCB(Game_FastSP,this,(CSettings::SettingChangedFunc)StaticRefreshSettings);
_Settings->RegisterChangeCB(Game_RspAudioSignal,this,(CSettings::SettingChangedFunc)StaticRefreshSettings);
RefreshSettings();
}
@ -50,6 +52,7 @@ CGameSettings::~CGameSettings()
_Settings->UnregisterChangeCB(Game_SyncViaAudio,this,(CSettings::SettingChangedFunc)StaticRefreshSettings);
_Settings->UnregisterChangeCB(Game_32Bit,this,(CSettings::SettingChangedFunc)StaticRefreshSettings);
_Settings->UnregisterChangeCB(Game_FastSP,this,(CSettings::SettingChangedFunc)StaticRefreshSettings);
_Settings->UnregisterChangeCB(Game_RspAudioSignal,this,(CSettings::SettingChangedFunc)StaticRefreshSettings);
m_Registered = false;
}
@ -67,4 +70,5 @@ void CGameSettings::RefreshSettings()
m_bSyncToAudio = m_bFixedAudio ? _Settings->LoadBool(Game_SyncViaAudio) : false;
m_b32Bit = _Settings->LoadBool(Game_32Bit);
m_bFastSP = _Settings->LoadBool(Game_FastSP);
m_RspAudioSignal= _Settings->LoadBool(Game_RspAudioSignal);
}

View File

@ -16,6 +16,7 @@ public:
inline static bool bSyncToAudio ( void ) { return m_bSyncToAudio; }
inline static bool b32BitCore ( void ) { return m_b32Bit; }
inline static bool bFastSP ( void ) { return m_bFastSP; }
inline static bool RspAudioSignal( void ) { return m_RspAudioSignal; }
private:
static void StaticRefreshSettings (CGameSettings * _this)
@ -36,6 +37,7 @@ private:
static bool m_bSyncToAudio;
static bool m_bFastSP;
static bool m_b32Bit;
static bool m_RspAudioSignal;
static int m_RefCount;
static bool m_Registered;