[Audio] Use sync to audio from project

This commit is contained in:
zilmar 2017-09-28 21:43:58 +10:00
parent 0c1b5d3fb9
commit a5251619b7
14 changed files with 75 additions and 158 deletions

View File

@ -3,334 +3,270 @@
Good Name=A Bug's Life (U) Good Name=A Bug's Life (U)
BufferDivider=60 BufferDivider=60
BufferLevel=2 BufferLevel=2
SyncAudio=1
[E6A95A4F-BAD2EA23-C:45] [E6A95A4F-BAD2EA23-C:45]
Good Name=Aidyn Chronicles - The First Mage (U) [!] (V1.0) Good Name=Aidyn Chronicles - The First Mage (U) [!] (V1.0)
BufferDivider=60 BufferDivider=60
BufferLevel=2 BufferLevel=2
SyncAudio=1
[112051D2-68BEF8AC-C:45] [112051D2-68BEF8AC-C:45]
Good Name=Aidyn Chronicles - The First Mage (U) [!] (V1.1) Good Name=Aidyn Chronicles - The First Mage (U) [!] (V1.1)
BufferDivider=60 BufferDivider=60
BufferLevel=2 BufferLevel=2
SyncAudio=1
[1FB5D932-3BA9481B-C:45] [1FB5D932-3BA9481B-C:45]
Good Name=Armorines - Project S.W.A.R.M. (U) Good Name=Armorines - Project S.W.A.R.M. (U)
SyncAudio=0
[4C52BBB2-CEAB0F6B-C:45] [4C52BBB2-CEAB0F6B-C:45]
Good Name=Army Men - Air Combat (U) Good Name=Army Men - Air Combat (U)
SyncAudio=0
[B20F73B6-2975FC34-C:45] [B20F73B6-2975FC34-C:45]
Good Name=Army Men - Sarge's Heroes 2 (U) Good Name=Army Men - Sarge's Heroes 2 (U)
SyncAudio=0
[A4BF9306-BF0CDFD1-C:45] [A4BF9306-BF0CDFD1-C:45]
Good Name=Banjo-Kazooie (U) (V1.0) Good Name=Banjo-Kazooie (U) (V1.0)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[CD7559AC-B26CF5AE-C:45] [CD7559AC-B26CF5AE-C:45]
Good Name=Banjo-Kazooie (U) (V1.1) Good Name=Banjo-Kazooie (U) (V1.1)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[C2E9AA9A-475D70AA-C:45] [C2E9AA9A-475D70AA-C:45]
Good Name=Banjo-Tooie (U) Good Name=Banjo-Tooie (U)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[6AA4DDE7-E3E2F4E7-C:45] [6AA4DDE7-E3E2F4E7-C:45]
Good Name=BattleTanx (U) Good Name=BattleTanx (U)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[75A4E247-6008963D-C:45] [75A4E247-6008963D-C:45]
Good Name=BattleTanx - Global Assault (U) Good Name=BattleTanx - Global Assault (U)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[EDF419A8-BF1904CC-C:45] [EDF419A8-BF1904CC-C:45]
Good Name=Beetle Adventure Racing! (U) (M3) Good Name=Beetle Adventure Racing! (U) (M3)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[7C647C25-D9D901E6-C:45] [7C647C25-D9D901E6-C:45]
Good Name=Blast Corps (U) (V1.0) Good Name=Blast Corps (U) (V1.0)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[7C647E65-1948D305-C:45] [7C647E65-1948D305-C:45]
Good Name=Blast Corps (U) (V1.1) Good Name=Blast Corps (U) (V1.1)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[5326696F-FE9A99C3-C:45] [5326696F-FE9A99C3-C:45]
Good Name=Body Harvest (U) Good Name=Body Harvest (U)
BufferDivider=95 BufferDivider=95
SyncAudio=1
[F568D51E-7E49BA1E-C:45] [F568D51E-7E49BA1E-C:45]
Good Name=Bomberman 64 (U) Good Name=Bomberman 64 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[F35D5F95-8AFE3D69-C:45] [F35D5F95-8AFE3D69-C:45]
Good Name=Castlevania (U) (V1.0) Good Name=Castlevania (U) (V1.0)
BufferDivider=60 BufferDivider=60
BufferLevel=2 BufferLevel=2
SyncAudio=1
[F35D5335-B7667CB7-C:45] [F35D5335-B7667CB7-C:45]
Good Name=Castlevania (U) (V1.1) Good Name=Castlevania (U) (V1.1)
BufferDivider=60 BufferDivider=60
BufferLevel=2 BufferLevel=2
SyncAudio=1
[4BCDFF47-AAA3AF8F-C:45] [4BCDFF47-AAA3AF8F-C:45]
Good Name=Castlevania (U) (V1.2) Good Name=Castlevania (U) (V1.2)
BufferDivider=60 BufferDivider=60
BufferLevel=2 BufferLevel=2
SyncAudio=1
[30C7AC50-7704072D-C:45] [30C7AC50-7704072D-C:45]
Good Name=Conker's Bad Fur Day (U) Good Name=Conker's Bad Fur Day (U)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[46A3F7AF-0F7591D0-C:45] [46A3F7AF-0F7591D0-C:45]
Good Name=Cruis'n Exotica (U) Good Name=Cruis'n Exotica (U)
[FF2F2FB4-D161149A-C:45] [FF2F2FB4-D161149A-C:45]
Good Name=Cruis'n USA (U) (V1.0) Good Name=Cruis'n USA (U) (V1.0)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[5306CF45-CBC49250-C:45] [5306CF45-CBC49250-C:45]
Good Name=Cruis'n USA (U) (V1.1) Good Name=Cruis'n USA (U) (V1.1)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[B3402554-7340C004-C:45] [B3402554-7340C004-C:45]
Good Name=Cruis'n USA (U) (V1.2) Good Name=Cruis'n USA (U) (V1.2)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[DFE61153-D76118E6-C:45] [DFE61153-D76118E6-C:45]
Good Name=Cruis'n World (U) Good Name=Cruis'n World (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[DEE584A2-0F161187-C:45] [DEE584A2-0F161187-C:45]
Good Name=Destruction Derby 64 (U) Good Name=Destruction Derby 64 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[53D440E7-7519B011-C:45] [53D440E7-7519B011-C:45]
Good Name=Diddy Kong Racing (U) (M2) (V1.0) Good Name=Diddy Kong Racing (U) (M2) (V1.0)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[E402430D-D2FCFC9D-C:45] [E402430D-D2FCFC9D-C:45]
Good Name=Diddy Kong Racing (U) (M2) (V1.1) Good Name=Diddy Kong Racing (U) (M2) (V1.1)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[EC58EABF-AD7C7169-C:45] [EC58EABF-AD7C7169-C:45]
Good Name=Donkey Kong 64 (U) Good Name=Donkey Kong 64 (U)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[A83E101A-E937B69D-C:45] [A83E101A-E937B69D-C:45]
Good Name=Doom 64 (U) (V1.0) Good Name=Doom 64 (U) (V1.0)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[423E96F4-CE88F05B-C:45] [423E96F4-CE88F05B-C:45]
Good Name=Doom 64 (U) (V1.1) Good Name=Doom 64 (U) (V1.1)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[07861842-A12EBC9F-C:45] [07861842-A12EBC9F-C:45]
Good Name=Excitebike 64 (U) (V1.0) Good Name=Excitebike 64 (U) (V1.0)
[F9D411E3-7CB29BC0-C:45] [F9D411E3-7CB29BC0-C:45]
Good Name=Excitebike 64 (U) (V1.1) Good Name=Excitebike 64 (U) (V1.1)
[FDA245D2-A74A3D47-C:45] [FDA245D2-A74A3D47-C:45]
Good Name=Extreme-G (U) Good Name=Extreme-G (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[B30ED978-3003C9F9-C:45] [B30ED978-3003C9F9-C:45]
Good Name=F-ZERO X (U) Good Name=F-ZERO X (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[4252A5AD-AE6FBF4E-C:45] [4252A5AD-AE6FBF4E-C:45]
Good Name=Goemon's Great Adventure (U) Good Name=Goemon's Great Adventure (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[DCBC50D1-09FD1AA3-C:45] [DCBC50D1-09FD1AA3-C:45]
Good Name=GoldenEye 007 (U) Good Name=GoldenEye 007 (U)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[C7C98F8E-42145DDE-C:45] [C7C98F8E-42145DDE-C:45]
Good Name=Hot Wheels Turbo Racing (U) Good Name=Hot Wheels Turbo Racing (U)
[8A6009B6-94ACE150-C:45] [8A6009B6-94ACE150-C:45]
Good Name=Jet Force Gemini (U) Good Name=Jet Force Gemini (U)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[9E8FE2BA-8B270770-C:45] [9E8FE2BA-8B270770-C:45]
Good Name=Killer Instinct Gold (U) (V1.0) Good Name=Killer Instinct Gold (U) (V1.0)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[9E8FCDFA-49F5652B-C:45] [9E8FCDFA-49F5652B-C:45]
Good Name=Killer Instinct Gold (U) (V1.1) Good Name=Killer Instinct Gold (U) (V1.1)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[F908CA4C-36464327-C:45] [F908CA4C-36464327-C:45]
Good Name=Killer Instinct Gold (U) (V1.2) Good Name=Killer Instinct Gold (U) (V1.2)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[7F304099-52CF5276-C:4A] [7F304099-52CF5276-C:4A]
Good Name=Last Legion UX (J) Good Name=Last Legion UX (J)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[0160E9E5-29A4CB68-C:45] [0160E9E5-29A4CB68-C:45]
Good Name=Last Legion UX (J) [T] Good Name=Last Legion UX (J) [T]
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[664BA3D4-678A80B7-C:45] [664BA3D4-678A80B7-C:45]
Good Name=Mario Golf (U) Good Name=Mario Golf (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[3E5055B6-2E92DA52-C:45] [3E5055B6-2E92DA52-C:45]
Good Name=Mario Kart 64 (U) Good Name=Mario Kart 64 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[7C3829D9-6E8247CE-C:45] [7C3829D9-6E8247CE-C:45]
Good Name=Mario Party 3 (U) Good Name=Mario Party 3 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[5001CF4F-F30CB3BD-C:45] [5001CF4F-F30CB3BD-C:45]
Good Name=Mario Tennis (U) Good Name=Mario Tennis (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[28768D6D-B379976C-C:45] [28768D6D-B379976C-C:45]
Good Name=Monaco Grand Prix (U) Good Name=Monaco Grand Prix (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[5AC383E1-D712E387-C:45] [5AC383E1-D712E387-C:45]
Good Name=Monopoly (U) (M2) Good Name=Monopoly (U) (M2)
[FCBCCB21-72903C6B-C:45] [FCBCCB21-72903C6B-C:45]
Good Name=Mystical Ninja Starring Goemon (U) Good Name=Mystical Ninja Starring Goemon (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[DF331A18-5FD4E044-C:45] [DF331A18-5FD4E044-C:45]
Good Name=NASCAR 2000 (U) Good Name=NASCAR 2000 (U)
[591A806E-A5E6921D-C:45] [591A806E-A5E6921D-C:45]
Good Name=NHL 99 (U) Good Name=NHL 99 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[82EFDC30-806A2461-C:45] [82EFDC30-806A2461-C:45]
Good Name=NHL Blades of Steel '99 (U) Good Name=NHL Blades of Steel '99 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[6DFDCDC3-4DE701C8-C:45] [6DFDCDC3-4DE701C8-C:45]
Good Name=NHL Breakaway 98 (U) Good Name=NHL Breakaway 98 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=0
[441768D0-7D73F24F-C:45] [441768D0-7D73F24F-C:45]
Good Name=NHL Breakaway 99 (U) Good Name=NHL Breakaway 99 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=0
[E6419BC5-69011DE3-C:45] [E6419BC5-69011DE3-C:45]
Good Name=Ogre Battle 64 - Person of Lordly Caliber (U) (V1.0) Good Name=Ogre Battle 64 - Person of Lordly Caliber (U) (V1.0)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[0ADAECA7-B17F9795-C:45] [0ADAECA7-B17F9795-C:45]
Good Name=Ogre Battle 64 - Person of Lordly Caliber (U) (V1.1) Good Name=Ogre Battle 64 - Person of Lordly Caliber (U) (V1.1)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[65EEE53A-ED7D733C-C:45] [65EEE53A-ED7D733C-C:45]
Good Name=Paper Mario (U) Good Name=Paper Mario (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[DDF460CC-3CA634C0-C:45] [DDF460CC-3CA634C0-C:45]
Good Name=Perfect Dark (U) (V1.0) Good Name=Perfect Dark (U) (V1.0)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[41F2B98F-B458B466-C:45] [41F2B98F-B458B466-C:45]
Good Name=Perfect Dark (U) (V1.1) Good Name=Perfect Dark (U) (V1.1)
BufferDivider=30 BufferDivider=30
BufferLevel=2 BufferLevel=2
SyncAudio=1
[C851961C-78FCAAFA-C:45] [C851961C-78FCAAFA-C:45]
Good Name=Pilotwings 64 (U) Good Name=Pilotwings 64 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[03571182-892FD06D-C:45] [03571182-892FD06D-C:45]
Good Name=Pokemon Stadium 2 (U) Good Name=Pokemon Stadium 2 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[BDA8F143-B1AF2D62-C:45] [BDA8F143-B1AF2D62-C:45]
Good Name=Quake II (U) Good Name=Quake II (U)
BufferDivider=60 BufferDivider=60
SyncAudio=0
[0F1FA987-BFC1AFA6-C:45] [0F1FA987-BFC1AFA6-C:45]
Good Name=Re-Volt (U) Good Name=Re-Volt (U)
@ -338,7 +274,6 @@ Good Name=Re-Volt (U)
[F050746C-247B820B-C:45] [F050746C-247B820B-C:45]
Good Name=Road Rash 64 (U) Good Name=Road Rash 64 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[0C5EE085-A167DD3E-C:45] [0C5EE085-A167DD3E-C:45]
Good Name=Rocket - Robot on Wheels (U) Good Name=Rocket - Robot on Wheels (U)
@ -346,7 +281,6 @@ Good Name=Rocket - Robot on Wheels (U)
[2500267E-2A7EC3CE-C:45] [2500267E-2A7EC3CE-C:45]
Good Name=RR64 - Ridge Racer 64 (U) Good Name=RR64 - Ridge Racer 64 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=0
[769147F3-2033C10E-C:45] [769147F3-2033C10E-C:45]
Good Name=S.C.A.R.S. (U) Good Name=S.C.A.R.S. (U)
@ -372,12 +306,10 @@ Good Name=StarCraft 64 (U)
[635A2BFF-8B022326-C:45] [635A2BFF-8B022326-C:45]
Good Name=Super Mario 64 (U) Good Name=Super Mario 64 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[916B8B5B-780B85A4-C:45] [916B8B5B-780B85A4-C:45]
Good Name=Super Smash Bros. (U) Good Name=Super Smash Bros. (U)
BufferDivider=30 BufferDivider=30
SyncAudio=1
[204EC022-B119D185-C:45] [204EC022-B119D185-C:45]
Good Name=Tony Hawk's Pro Skater (U) (V1.0) Good Name=Tony Hawk's Pro Skater (U) (V1.0)
@ -386,7 +318,7 @@ Good Name=Tony Hawk's Pro Skater (U) (V1.0)
Good Name=Tony Hawk's Pro Skater (U) (V1.1) Good Name=Tony Hawk's Pro Skater (U) (V1.1)
[99150E18-1266E6A5-C:45] [99150E18-1266E6A5-C:45]
Good Name=Tony Hawk's Pro Skater 2 (U) Good Name=Tony Hawk's Pro Skater 2 (U
[1A7F70B5-00B7B9FD-C:45] [1A7F70B5-00B7B9FD-C:45]
Good Name=Tony Hawk's Pro Skater 3 (U) Good Name=Tony Hawk's Pro Skater 3 (U)
@ -412,17 +344,14 @@ Good Name=Turok 3 - Shadow of Oblivion (U)
[3C059038-C8BF2182-C:45] [3C059038-C8BF2182-C:45]
Good Name=V-Rally Edition 99 (U) Good Name=V-Rally Edition 99 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[EA71056A-E4214847-C:45] [EA71056A-E4214847-C:45]
Good Name=Vigilante 8 (U) Good Name=Vigilante 8 (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[F5C5866D-052713D9-C:45] [F5C5866D-052713D9-C:45]
Good Name=Vigilante 8 - 2nd Offense (U) Good Name=Vigilante 8 - 2nd Offense (U)
BufferDivider=60 BufferDivider=60
SyncAudio=1
[ED98957E-8242DCAC-C:45] [ED98957E-8242DCAC-C:45]
Good Name=WinBack - Covert Operations (U) Good Name=WinBack - Covert Operations (U)
@ -430,4 +359,3 @@ Good Name=WinBack - Covert Operations (U)
[2337D8E8-6B8E7CEC-C:45] [2337D8E8-6B8E7CEC-C:45]
Good Name=Yoshi's Story (U) (M2) Good Name=Yoshi's Story (U) (M2)
BufferDivider=60 BufferDivider=60
SyncAudio=1

View File

@ -17,6 +17,8 @@ CSettings * g_settings = NULL;
CSettings::CSettings() : CSettings::CSettings() :
m_Set_EnableAudio(0), m_Set_EnableAudio(0),
m_Set_SyncAudio(0),
m_Set_FullSpeed(0),
m_Set_basic_mode(0), m_Set_basic_mode(0),
m_Set_debugger(0), m_Set_debugger(0),
m_Set_log_dir(0), m_Set_log_dir(0),
@ -28,7 +30,8 @@ CSettings::CSettings() :
m_Volume(100), m_Volume(100),
m_BufferDivider(90), m_BufferDivider(90),
m_BufferLevel(4), m_BufferLevel(4),
m_SyncAudio(false) m_SyncAudio(false),
m_FullSpeed(true)
{ {
memset(m_log_dir, 0, sizeof(m_log_dir)); memset(m_log_dir, 0, sizeof(m_log_dir));
RegisterSettings(); RegisterSettings();
@ -38,6 +41,8 @@ CSettings::CSettings() :
if (m_Set_basic_mode != 0) { SettingsRegisterChange(true, m_Set_basic_mode, this, stSettingsChanged); } if (m_Set_basic_mode != 0) { SettingsRegisterChange(true, m_Set_basic_mode, this, stSettingsChanged); }
if (m_Set_debugger != 0) { SettingsRegisterChange(true, m_Set_debugger, this, stSettingsChanged); } if (m_Set_debugger != 0) { SettingsRegisterChange(true, m_Set_debugger, this, stSettingsChanged); }
if (m_Set_log_flush != 0) { SettingsRegisterChange(true, m_Set_log_flush, this, stSettingsChanged); } if (m_Set_log_flush != 0) { SettingsRegisterChange(true, m_Set_log_flush, this, stSettingsChanged); }
if (m_Set_SyncAudio != 0) { SettingsRegisterChange(true, m_Set_SyncAudio, this, stSettingsChanged); }
if (m_Set_FullSpeed != 0) { SettingsRegisterChange(true, m_Set_FullSpeed, this, stSettingsChanged); }
SettingsRegisterChange(false, Set_Volume, this, stSettingsChanged); SettingsRegisterChange(false, Set_Volume, this, stSettingsChanged);
SettingsRegisterChange(false, Set_Logging_MD5, this, stLogLevelChanged); SettingsRegisterChange(false, Set_Logging_MD5, this, stLogLevelChanged);
@ -54,6 +59,8 @@ CSettings::~CSettings()
if (m_Set_basic_mode != 0) { SettingsUnregisterChange(true, m_Set_basic_mode, this, stSettingsChanged); } if (m_Set_basic_mode != 0) { SettingsUnregisterChange(true, m_Set_basic_mode, this, stSettingsChanged); }
if (m_Set_debugger != 0) { SettingsUnregisterChange(true, m_Set_debugger, this, stSettingsChanged); } if (m_Set_debugger != 0) { SettingsUnregisterChange(true, m_Set_debugger, this, stSettingsChanged); }
if (m_Set_log_flush != 0) { SettingsUnregisterChange(true, m_Set_log_flush, this, stSettingsChanged); } if (m_Set_log_flush != 0) { SettingsUnregisterChange(true, m_Set_log_flush, this, stSettingsChanged); }
if (m_Set_SyncAudio != 0) { SettingsUnregisterChange(true, m_Set_SyncAudio, this, stSettingsChanged); }
if (m_Set_FullSpeed != 0) { SettingsUnregisterChange(true, m_Set_FullSpeed, this, stSettingsChanged); }
SettingsUnregisterChange(false, Set_Volume, this, stSettingsChanged); SettingsUnregisterChange(false, Set_Volume, this, stSettingsChanged);
SettingsUnregisterChange(false, Set_Logging_MD5, this, stLogLevelChanged); SettingsUnregisterChange(false, Set_Logging_MD5, this, stLogLevelChanged);
@ -68,6 +75,8 @@ void CSettings::RegisterSettings(void)
{ {
SetModuleName("default"); SetModuleName("default");
m_Set_EnableAudio = FindSystemSettingId("Enable Audio"); m_Set_EnableAudio = FindSystemSettingId("Enable Audio");
m_Set_SyncAudio = FindSystemSettingId("Sync Audio");
m_Set_FullSpeed = FindSystemSettingId("Full Speed");
m_Set_basic_mode = FindSystemSettingId("Basic Mode"); m_Set_basic_mode = FindSystemSettingId("Basic Mode");
m_Set_debugger = FindSystemSettingId("Debugger"); m_Set_debugger = FindSystemSettingId("Debugger");
m_Set_log_flush = FindSystemSettingId("Log Auto Flush"); m_Set_log_flush = FindSystemSettingId("Log Auto Flush");
@ -83,7 +92,6 @@ void CSettings::RegisterSettings(void)
RegisterSetting(Set_Logging_Driver, Data_DWORD_General, "Driver", "Logging", g_ModuleLogLevel[TraceAudioDriver], NULL); RegisterSetting(Set_Logging_Driver, Data_DWORD_General, "Driver", "Logging", g_ModuleLogLevel[TraceAudioDriver], NULL);
RegisterSetting(Set_BufferDivider, Data_DWORD_Game, "BufferDivider", "", 90, NULL); RegisterSetting(Set_BufferDivider, Data_DWORD_Game, "BufferDivider", "", 90, NULL);
RegisterSetting(Set_BufferLevel, Data_DWORD_Game, "BufferLevel", "", 4, NULL); RegisterSetting(Set_BufferLevel, Data_DWORD_Game, "BufferLevel", "", 4, NULL);
RegisterSetting(Set_SyncAudio, Data_DWORD_Game, "SyncAudio", "", (uint32_t)false, NULL);
LogLevelChanged(); LogLevelChanged();
} }
@ -113,11 +121,6 @@ void CSettings::SetBufferLevel(uint32_t BufferLevel)
SetSetting(Set_BufferLevel, BufferLevel); SetSetting(Set_BufferLevel, BufferLevel);
} }
void CSettings::SetSyncAudio(bool Enabled)
{
SetSetting(Set_SyncAudio, Enabled ? 1 : 0);
}
void CSettings::LogLevelChanged(void) void CSettings::LogLevelChanged(void)
{ {
g_ModuleLogLevel[TraceMD5] = GetSetting(Set_Logging_MD5); g_ModuleLogLevel[TraceMD5] = GetSetting(Set_Logging_MD5);
@ -136,7 +139,8 @@ void CSettings::ReadSettings(void)
m_debugger_enabled = m_advanced_options && m_Set_debugger ? GetSystemSetting(m_Set_debugger) == 1 : false; m_debugger_enabled = m_advanced_options && m_Set_debugger ? GetSystemSetting(m_Set_debugger) == 1 : false;
m_BufferDivider = GetSetting(Set_BufferDivider); m_BufferDivider = GetSetting(Set_BufferDivider);
m_BufferLevel = GetSetting(Set_BufferLevel); m_BufferLevel = GetSetting(Set_BufferLevel);
m_SyncAudio = GetSetting(Set_SyncAudio) != 0; m_SyncAudio = m_Set_SyncAudio ? GetSystemSetting(m_Set_SyncAudio) != 0 : false;
m_FullSpeed = m_Set_FullSpeed ? GetSystemSetting(m_Set_FullSpeed) != 0 : false;
if (m_Set_log_dir != 0) if (m_Set_log_dir != 0)
{ {

View File

@ -22,6 +22,7 @@ public:
inline uint32_t BufferDivider(void) const { return m_BufferDivider; } inline uint32_t BufferDivider(void) const { return m_BufferDivider; }
inline uint32_t BufferLevel(void) const { return m_BufferLevel; } inline uint32_t BufferLevel(void) const { return m_BufferLevel; }
inline bool SyncAudio(void) const { return m_SyncAudio; } inline bool SyncAudio(void) const { return m_SyncAudio; }
inline bool FullSpeed(void) const { return m_FullSpeed; }
inline bool FlushLogs(void) const { return m_FlushLogs; } inline bool FlushLogs(void) const { return m_FlushLogs; }
inline const char * log_dir(void) const { return m_log_dir; } inline const char * log_dir(void) const { return m_log_dir; }
@ -29,7 +30,6 @@ public:
void SetVolume(uint32_t Volume); void SetVolume(uint32_t Volume);
void SetBufferDivider(uint32_t BufferDivider); void SetBufferDivider(uint32_t BufferDivider);
void SetBufferLevel(uint32_t BufferLevel); void SetBufferLevel(uint32_t BufferLevel);
void SetSyncAudio(bool Enabled);
void ReadSettings(); void ReadSettings();
private: private:
@ -46,6 +46,8 @@ private:
void LogLevelChanged(void); void LogLevelChanged(void);
short m_Set_EnableAudio; short m_Set_EnableAudio;
short m_Set_SyncAudio;
short m_Set_FullSpeed;
short m_Set_basic_mode; short m_Set_basic_mode;
short m_Set_debugger; short m_Set_debugger;
short m_Set_log_dir; short m_Set_log_dir;
@ -59,6 +61,7 @@ private:
uint32_t m_BufferDivider; uint32_t m_BufferDivider;
uint32_t m_BufferLevel; uint32_t m_BufferLevel;
bool m_SyncAudio; bool m_SyncAudio;
bool m_FullSpeed;
}; };
extern CSettings * g_settings; extern CSettings * g_settings;

View File

@ -125,7 +125,6 @@ public:
g_settings->SetBufferDivider(atoi(buffer)); g_settings->SetBufferDivider(atoi(buffer));
m_BufferLevel.GetWindowText(buffer, sizeof(buffer)); m_BufferLevel.GetWindowText(buffer, sizeof(buffer));
g_settings->SetBufferLevel(atoi(buffer)); g_settings->SetBufferLevel(atoi(buffer));
g_settings->SetSyncAudio(m_btnSyncAudio.GetCheck() == BST_CHECKED);
FlushSettings(); FlushSettings();
return true; return true;
@ -134,7 +133,6 @@ public:
private: private:
CEdit m_BufferDivider; CEdit m_BufferDivider;
CEdit m_BufferLevel; CEdit m_BufferLevel;
CButton m_btnSyncAudio;
LRESULT ItemChangedNotify(NMHDR* /*pNMHDR*/) LRESULT ItemChangedNotify(NMHDR* /*pNMHDR*/)
{ {

View File

@ -22,5 +22,4 @@ enum
Set_Logging_Driver, Set_Logging_Driver,
Set_BufferDivider, Set_BufferDivider,
Set_BufferLevel, Set_BufferLevel,
Set_SyncAudio,
}; };

View File

@ -116,10 +116,6 @@ void CAudio::InterruptTimerDone()
{ {
m_Status &= ~ai_busy; m_Status &= ~ai_busy;
} }
if (g_Reg->m_AudioIntrReg == 0)
{
g_System->SyncToAudio();
}
WriteTrace(TraceAudio, TraceDebug, "Done"); WriteTrace(TraceAudio, TraceDebug, "Done");
} }
@ -157,4 +153,4 @@ void CAudio::SetFrequency(uint32_t Dacrate, uint32_t System)
//m_BytesPerSecond = 128024; //m_BytesPerSecond = 128024;
m_FramesPerSecond = System == SYSTEM_PAL ? 50 : 60; m_FramesPerSecond = System == SYSTEM_PAL ? 50 : 60;
} }

View File

@ -475,6 +475,7 @@ bool CN64System::RunDiskImage(const char * FileLoc)
void CN64System::CloseSystem() void CN64System::CloseSystem()
{ {
WriteTrace(TraceN64System, TraceDebug, "Start"); WriteTrace(TraceN64System, TraceDebug, "Start");
g_Settings->SaveBool(Game_FullSpeed, true);
if (g_BaseSystem) if (g_BaseSystem)
{ {
g_BaseSystem->CloseCpu(); g_BaseSystem->CloseCpu();
@ -2069,33 +2070,6 @@ void CN64System::RunRSP()
WriteTrace(TraceRSP, TraceDebug, "Done (SP Status %X)", m_Reg.SP_STATUS_REG); WriteTrace(TraceRSP, TraceDebug, "Done (SP Status %X)", m_Reg.SP_STATUS_REG);
} }
void CN64System::SyncToAudio()
{
if (!bSyncToAudio() || !bLimitFPS())
{
return;
}
PROFILE_TIMERS PreviousTimer = Timer_None;
if (bShowCPUPer())
{
PreviousTimer = m_CPU_Usage.StartTimer(Timer_Idel);
}
for (int i = 0; i < 50; i++)
{
if (g_Reg->m_AudioIntrReg != 0)
{
WriteTrace(TraceAudio, TraceDebug, "Audio Interrupt done (%d)", i);
break;
}
pjutil::Sleep(1);
}
if (bShowCPUPer())
{
m_CPU_Usage.StartTimer(PreviousTimer);
}
}
void CN64System::RefreshScreen() void CN64System::RefreshScreen()
{ {
PROFILE_TIMERS CPU_UsageAddr = Timer_None/*, ProfilingAddr = Timer_None*/; PROFILE_TIMERS CPU_UsageAddr = Timer_None/*, ProfilingAddr = Timer_None*/;
@ -2148,7 +2122,7 @@ void CN64System::RefreshScreen()
} }
g_MMU->UpdateFieldSerration((m_Reg.VI_STATUS_REG & 0x40) != 0); g_MMU->UpdateFieldSerration((m_Reg.VI_STATUS_REG & 0x40) != 0);
if ((bBasicMode() || bLimitFPS()) && !bSyncToAudio()) if ((bBasicMode() || bLimitFPS()) && (!bSyncToAudio() || !FullSpeed()))
{ {
if (bShowCPUPer()) { m_CPU_Usage.StartTimer(Timer_Idel); } if (bShowCPUPer()) { m_CPU_Usage.StartTimer(Timer_Idel); }
uint32_t FrameRate; uint32_t FrameRate;

View File

@ -67,9 +67,8 @@ public:
void ExternalEvent(SystemEvent action); //covers gui interacting and timers etc.. void ExternalEvent(SystemEvent action); //covers gui interacting and timers etc..
void StartEmulation(bool NewThread); void StartEmulation(bool NewThread);
void EndEmulation(); void EndEmulation();
void SyncToAudio();
void AlterSpeed(const CSpeedLimiter::ESpeedChange SpeedChange) { m_Limiter.AlterSpeed(SpeedChange); } void AlterSpeed(const CSpeedLimiter::ESpeedChange SpeedChange) { m_Limiter.AlterSpeed(SpeedChange); }
void SetSpeed(int Speed) { m_Limiter.SetSpeed(Speed); } void SetSpeed(int Speed) { m_Limiter.SetSpeed(Speed); }
int GetSpeed(void) const { return m_Limiter.GetSpeed(); } int GetSpeed(void) const { return m_Limiter.GetSpeed(); }
int GetBaseSpeed(void) const { return m_Limiter.GetBaseSpeed(); } int GetBaseSpeed(void) const { return m_Limiter.GetBaseSpeed(); }
void Reset(bool bInitReg, bool ClearMenory); void Reset(bool bInitReg, bool ClearMenory);

View File

@ -27,8 +27,8 @@ bool CGameSettings::m_DelayDP = false;
bool CGameSettings::m_DelaySI = false; bool CGameSettings::m_DelaySI = false;
uint32_t CGameSettings::m_RdramSize = 0; uint32_t CGameSettings::m_RdramSize = 0;
bool CGameSettings::m_bFixedAudio = true; bool CGameSettings::m_bFixedAudio = true;
bool CGameSettings::m_bSyncingToAudio = true;
bool CGameSettings::m_bSyncToAudio = true; bool CGameSettings::m_bSyncToAudio = true;
bool CGameSettings::m_FullSpeed = true;
bool CGameSettings::m_bFastSP = true; bool CGameSettings::m_bFastSP = true;
bool CGameSettings::m_b32Bit = true; bool CGameSettings::m_b32Bit = true;
bool CGameSettings::m_RspAudioSignal; bool CGameSettings::m_RspAudioSignal;
@ -57,7 +57,8 @@ void CGameSettings::RefreshGameSettings()
m_DelaySI = g_Settings->LoadBool(Game_DelaySI); m_DelaySI = g_Settings->LoadBool(Game_DelaySI);
m_DelayDP = g_Settings->LoadBool(Game_DelayDP); m_DelayDP = g_Settings->LoadBool(Game_DelayDP);
m_bFixedAudio = g_Settings->LoadBool(Game_FixedAudio); m_bFixedAudio = g_Settings->LoadBool(Game_FixedAudio);
m_bSyncToAudio = m_bFixedAudio ? g_Settings->LoadBool(Game_SyncViaAudio) : false; m_bSyncToAudio = g_Settings->LoadBool(Game_SyncViaAudio);
m_FullSpeed = g_Settings->LoadBool(Game_FullSpeed);
m_b32Bit = g_Settings->LoadBool(Game_32Bit); m_b32Bit = g_Settings->LoadBool(Game_32Bit);
#ifdef ANDROID #ifdef ANDROID
m_bFastSP = false; m_bFastSP = false;
@ -72,7 +73,6 @@ void CGameSettings::RefreshGameSettings()
m_SystemType = (SYSTEM_TYPE)g_Settings->LoadDword(Game_SystemType); m_SystemType = (SYSTEM_TYPE)g_Settings->LoadDword(Game_SystemType);
m_CpuType = (CPU_TYPE)g_Settings->LoadDword(Game_CpuType); m_CpuType = (CPU_TYPE)g_Settings->LoadDword(Game_CpuType);
m_OverClockModifier = g_Settings->LoadDword(Game_OverClockModifier); m_OverClockModifier = g_Settings->LoadDword(Game_OverClockModifier);
m_bSyncingToAudio = m_bSyncToAudio;
if (m_CountPerOp == 0) if (m_CountPerOp == 0)
{ {
m_CountPerOp = 2; m_CountPerOp = 2;
@ -84,6 +84,6 @@ void CGameSettings::RefreshGameSettings()
void CGameSettings::SpeedChanged(int SpeedLimit) void CGameSettings::SpeedChanged(int SpeedLimit)
{ {
int FullSpeed = g_System->m_SystemType == SYSTEM_PAL ? 50 : 60; m_FullSpeed = (g_System->m_SystemType == SYSTEM_PAL ? 50 : 60) == SpeedLimit;
m_bSyncingToAudio = SpeedLimit == FullSpeed ? m_bSyncToAudio : false; g_Settings->SaveBool(Game_FullSpeed, m_FullSpeed);
} }

View File

@ -30,7 +30,8 @@ public:
inline static bool bDelaySI(void) { return m_DelaySI; } inline static bool bDelaySI(void) { return m_DelaySI; }
inline static uint32_t RdramSize(void) { return m_RdramSize; } inline static uint32_t RdramSize(void) { return m_RdramSize; }
inline static bool bFixedAudio(void) { return m_bFixedAudio; } inline static bool bFixedAudio(void) { return m_bFixedAudio; }
inline static bool bSyncToAudio(void) { return m_bSyncingToAudio; } inline static bool bSyncToAudio(void) { return m_bSyncToAudio; }
inline static bool FullSpeed(void) { return m_FullSpeed; }
inline static bool bFastSP(void) { return m_bFastSP; } inline static bool bFastSP(void) { return m_bFastSP; }
inline static bool b32BitCore(void) { return m_b32Bit; } inline static bool b32BitCore(void) { return m_b32Bit; }
inline static bool RspAudioSignal(void) { return m_RspAudioSignal; } inline static bool RspAudioSignal(void) { return m_RspAudioSignal; }
@ -61,8 +62,8 @@ private:
static bool m_DelaySI; static bool m_DelaySI;
static uint32_t m_RdramSize; static uint32_t m_RdramSize;
static bool m_bFixedAudio; static bool m_bFixedAudio;
static bool m_bSyncingToAudio;
static bool m_bSyncToAudio; static bool m_bSyncToAudio;
static bool m_FullSpeed;
static bool m_bFastSP; static bool m_bFastSP;
static bool m_b32Bit; static bool m_b32Bit;
static bool m_RspAudioSignal; static bool m_RspAudioSignal;

View File

@ -11,70 +11,71 @@
#include "stdafx.h" #include "stdafx.h"
#include "SettingsType-TempBool.h" #include "SettingsType-TempBool.h"
CSettingTypeTempBool::CSettingTypeTempBool(bool initialValue) : CSettingTypeTempBool::CSettingTypeTempBool(bool initialValue, const char * Name) :
m_value(initialValue) m_value(initialValue),
m_Name(Name ? Name : "")
{ {
} }
CSettingTypeTempBool::~CSettingTypeTempBool ( void ) CSettingTypeTempBool::~CSettingTypeTempBool(void)
{ {
} }
bool CSettingTypeTempBool::Load ( int /*Index*/, bool & Value ) const bool CSettingTypeTempBool::Load(int /*Index*/, bool & Value) const
{ {
Value = m_value; Value = m_value;
return true; return true;
} }
bool CSettingTypeTempBool::Load ( int /*Index*/, uint32_t & /*Value*/ ) const bool CSettingTypeTempBool::Load(int /*Index*/, uint32_t & /*Value*/) const
{ {
g_Notify->BreakPoint(__FILE__, __LINE__); g_Notify->BreakPoint(__FILE__, __LINE__);
return false; return false;
} }
bool CSettingTypeTempBool::Load ( int /*Index*/, stdstr & /*Value*/ ) const bool CSettingTypeTempBool::Load(int /*Index*/, stdstr & /*Value*/) const
{ {
g_Notify->BreakPoint(__FILE__, __LINE__); g_Notify->BreakPoint(__FILE__, __LINE__);
return false; return false;
} }
//return the default values //return the default values
void CSettingTypeTempBool::LoadDefault ( int /*Index*/, bool & /*Value*/ ) const void CSettingTypeTempBool::LoadDefault(int /*Index*/, bool & /*Value*/) const
{ {
g_Notify->BreakPoint(__FILE__, __LINE__); g_Notify->BreakPoint(__FILE__, __LINE__);
} }
void CSettingTypeTempBool::LoadDefault ( int /*Index*/, uint32_t & /*Value*/ ) const void CSettingTypeTempBool::LoadDefault(int /*Index*/, uint32_t & /*Value*/) const
{ {
g_Notify->BreakPoint(__FILE__, __LINE__); g_Notify->BreakPoint(__FILE__, __LINE__);
} }
void CSettingTypeTempBool::LoadDefault ( int /*Index*/, stdstr & /*Value*/ ) const void CSettingTypeTempBool::LoadDefault(int /*Index*/, stdstr & /*Value*/) const
{ {
g_Notify->BreakPoint(__FILE__, __LINE__); g_Notify->BreakPoint(__FILE__, __LINE__);
} }
void CSettingTypeTempBool::Save ( int /*Index*/, bool Value ) void CSettingTypeTempBool::Save(int /*Index*/, bool Value)
{ {
m_value = Value; m_value = Value;
} }
void CSettingTypeTempBool::Save ( int /*Index*/, uint32_t /*Value*/ ) void CSettingTypeTempBool::Save(int /*Index*/, uint32_t /*Value*/)
{ {
g_Notify->BreakPoint(__FILE__, __LINE__); g_Notify->BreakPoint(__FILE__, __LINE__);
} }
void CSettingTypeTempBool::Save ( int /*Index*/, const stdstr & /*Value*/ ) void CSettingTypeTempBool::Save(int /*Index*/, const stdstr & /*Value*/)
{ {
g_Notify->BreakPoint(__FILE__, __LINE__); g_Notify->BreakPoint(__FILE__, __LINE__);
} }
void CSettingTypeTempBool::Save ( int /*Index*/, const char * /*Value*/ ) void CSettingTypeTempBool::Save(int /*Index*/, const char * /*Value*/)
{ {
g_Notify->BreakPoint(__FILE__, __LINE__); g_Notify->BreakPoint(__FILE__, __LINE__);
} }
void CSettingTypeTempBool::Delete( int /*Index*/ ) void CSettingTypeTempBool::Delete(int /*Index*/)
{ {
g_Notify->BreakPoint(__FILE__, __LINE__); g_Notify->BreakPoint(__FILE__, __LINE__);
} }

View File

@ -16,31 +16,33 @@ class CSettingTypeTempBool :
public CSettingType public CSettingType
{ {
public: public:
CSettingTypeTempBool(bool initialValue ); CSettingTypeTempBool(bool initialValue, const char * name = NULL);
~CSettingTypeTempBool(); ~CSettingTypeTempBool();
bool IndexBasedSetting ( void ) const { return false; } bool IndexBasedSetting(void) const { return false; }
SettingType GetSettingType ( void ) const { return SettingType_BoolVariable; } SettingType GetSettingType(void) const { return SettingType_BoolVariable; }
bool IsSettingSet(void) const { return false; } bool IsSettingSet(void) const { return false; }
const char * GetName(void) const { return m_Name.c_str(); }
//return the values //return the values
bool Load ( int32_t Index, bool & Value ) const; bool Load(int32_t Index, bool & Value) const;
bool Load ( int32_t Index, uint32_t & Value ) const; bool Load(int32_t Index, uint32_t & Value) const;
bool Load ( int32_t Index, stdstr & Value ) const; bool Load(int32_t Index, stdstr & Value) const;
//return the default values //return the default values
void LoadDefault ( int32_t Index, bool & Value ) const; void LoadDefault(int32_t Index, bool & Value) const;
void LoadDefault ( int32_t Index, uint32_t & Value ) const; void LoadDefault(int32_t Index, uint32_t & Value) const;
void LoadDefault ( int32_t Index, stdstr & Value ) const; void LoadDefault(int32_t Index, stdstr & Value) const;
//Update the settings //Update the settings
void Save ( int32_t Index, bool Value ); void Save(int32_t Index, bool Value);
void Save ( int32_t Index, uint32_t Value ); void Save(int32_t Index, uint32_t Value);
void Save ( int32_t Index, const stdstr & Value ); void Save(int32_t Index, const stdstr & Value);
void Save ( int32_t Index, const char * Value ); void Save(int32_t Index, const char * Value);
// Delete the setting // Delete the setting
void Delete ( int32_t Index ); void Delete(int32_t Index);
private: private:
CSettingTypeTempBool(void); // Disable default constructor CSettingTypeTempBool(void); // Disable default constructor
@ -48,4 +50,5 @@ private:
CSettingTypeTempBool& operator=(const CSettingTypeTempBool&); // Disable assignment CSettingTypeTempBool& operator=(const CSettingTypeTempBool&); // Disable assignment
bool m_value; bool m_value;
std::string m_Name;
}; };

View File

@ -153,6 +153,7 @@ enum SettingID
Game_Transferpak_Sav, Game_Transferpak_Sav,
Game_LoadSaveAtStart, Game_LoadSaveAtStart,
Game_OverClockModifier, Game_OverClockModifier,
Game_FullSpeed,
// General Game running info // General Game running info
GameRunning_LoadingInProgress, GameRunning_LoadingInProgress,

View File

@ -226,6 +226,7 @@ void CSettings::AddHowToHandleSetting(const char * BaseDirectory)
AddHandler(Game_Transferpak_Sav, new CSettingTypeGame("Tpak-Sav-dir", Default_None)); AddHandler(Game_Transferpak_Sav, new CSettingTypeGame("Tpak-Sav-dir", Default_None));
AddHandler(Game_LoadSaveAtStart, new CSettingTypeTempBool(false)); AddHandler(Game_LoadSaveAtStart, new CSettingTypeTempBool(false));
AddHandler(Game_OverClockModifier, new CSettingTypeGame("OverClockModifier", Rdb_OverClockModifier)); AddHandler(Game_OverClockModifier, new CSettingTypeGame("OverClockModifier", Rdb_OverClockModifier));
AddHandler(Game_FullSpeed, new CSettingTypeTempBool(true, "Full Speed"));
//User Interface //User Interface
AddHandler(UserInterface_ShowCPUPer, new CSettingTypeApplication("", "Display CPU Usage", (uint32_t)false)); AddHandler(UserInterface_ShowCPUPer, new CSettingTypeApplication("", "Display CPU Usage", (uint32_t)false));
@ -420,7 +421,7 @@ uint32_t CSettings::FindSetting(CSettings * _this, const char * Name)
} }
return iter->first; return iter->first;
} }
if (Setting->GetSettingType() == SettingType_CfgFile) else if (Setting->GetSettingType() == SettingType_CfgFile)
{ {
CSettingTypeApplication * CfgSetting = (CSettingTypeApplication *)Setting; CSettingTypeApplication * CfgSetting = (CSettingTypeApplication *)Setting;
if (_stricmp(CfgSetting->GetKeyName(), Name) != 0) if (_stricmp(CfgSetting->GetKeyName(), Name) != 0)
@ -429,7 +430,7 @@ uint32_t CSettings::FindSetting(CSettings * _this, const char * Name)
} }
return iter->first; return iter->first;
} }
if (Setting->GetSettingType() == SettingType_SelectedDirectory) else if (Setting->GetSettingType() == SettingType_SelectedDirectory)
{ {
CSettingTypeSelectedDirectory * SelectedDirectory = (CSettingTypeSelectedDirectory *)Setting; CSettingTypeSelectedDirectory * SelectedDirectory = (CSettingTypeSelectedDirectory *)Setting;
if (_stricmp(SelectedDirectory->GetName(), Name) != 0) if (_stricmp(SelectedDirectory->GetName(), Name) != 0)
@ -438,6 +439,15 @@ uint32_t CSettings::FindSetting(CSettings * _this, const char * Name)
} }
return iter->first; return iter->first;
} }
else if (Setting->GetSettingType() == SettingType_BoolVariable)
{
CSettingTypeTempBool * BoolSetting = (CSettingTypeTempBool *)Setting;
if (_stricmp(BoolSetting->GetName(), Name) != 0)
{
continue;
}
return iter->first;
}
} }
return 0; return 0;
} }