mirror of
https://github.com/WinampDesktop/winamp.git
synced 2025-06-18 06:05:47 -04:00
Fix recompiler not auto-disabling with PGXP-CPU mode
This commit is contained in:
@ -441,22 +441,22 @@ void HostInterface::SetDefaultSettings(SettingsInterface& si)
|
||||
void HostInterface::LoadSettings(SettingsInterface& si)
|
||||
{
|
||||
g_settings.Load(si);
|
||||
|
||||
FixIncompatibleSettings();
|
||||
}
|
||||
|
||||
void HostInterface::FixIncompatibleSettings()
|
||||
void HostInterface::FixIncompatibleSettings(bool display_osd_messages)
|
||||
{
|
||||
if (g_settings.gpu_pgxp_enable)
|
||||
{
|
||||
if (g_settings.gpu_renderer == GPURenderer::Software)
|
||||
{
|
||||
Log_WarningPrintf("PGXP enabled with software renderer, disabling");
|
||||
if (display_osd_messages)
|
||||
AddOSDMessage("PGXP is incompatible with the software renderer, disabling PGXP.", 10.0f);
|
||||
g_settings.gpu_pgxp_enable = false;
|
||||
}
|
||||
else if (g_settings.gpu_pgxp_cpu && g_settings.cpu_execution_mode == CPUExecutionMode::Recompiler)
|
||||
{
|
||||
Log_WarningPrintf("Recompiler selected with PGXP CPU mode, falling back to cached interpreter");
|
||||
if (display_osd_messages)
|
||||
AddOSDMessage("PGXP CPU mode is incompatible with the recompiler, using Cached Interpreter instead.", 10.0f);
|
||||
g_settings.cpu_execution_mode = CPUExecutionMode::CachedInterpreter;
|
||||
}
|
||||
}
|
||||
|
@ -135,7 +135,7 @@ protected:
|
||||
virtual void SaveSettings(SettingsInterface& si);
|
||||
|
||||
/// Checks and fixes up any incompatible settings.
|
||||
virtual void FixIncompatibleSettings();
|
||||
virtual void FixIncompatibleSettings(bool display_osd_messages);
|
||||
|
||||
/// Checks for settings changes, std::move() the old settings away for comparing beforehand.
|
||||
virtual void CheckForSettingsChanges(const Settings& old_settings);
|
||||
|
Reference in New Issue
Block a user