diff options
| author | TurboK234 <hosode@gmail.com> | 2015-07-30 00:25:47 +0300 |
|---|---|---|
| committer | Henrik Söderström <hosode@gmail.com> | 2015-11-14 17:22:48 +0200 |
| commit | 6b9f4f511519e43a066522df45402f323ab0643b (patch) | |
| tree | 0c55fd02929ff43f8ea939a68921b2166d828d04 /Source/Core/DolphinWX/Frame.cpp | |
| parent | aad06e8f54e68c98bf4bea03cbc3336fb38ab5b3 (diff) | |
Added hotkeys for toggling different stereoscopy modes
Diffstat (limited to 'Source/Core/DolphinWX/Frame.cpp')
| -rw-r--r-- | Source/Core/DolphinWX/Frame.cpp | 64 |
1 files changed, 64 insertions, 0 deletions
diff --git a/Source/Core/DolphinWX/Frame.cpp b/Source/Core/DolphinWX/Frame.cpp index 75a9de022e..183a7b2517 100644 --- a/Source/Core/DolphinWX/Frame.cpp +++ b/Source/Core/DolphinWX/Frame.cpp @@ -1418,6 +1418,70 @@ void CFrame::ParseHotkeys() State::Load(g_saveSlot); } + if (IsHotkey(HK_TOGGLE_STEREO_SBS)) + { + if (g_Config.iStereoMode != STEREO_SBS) + { + // Current implementation of anaglyph stereoscopy uses a + // post-processing shader. Thus the shader needs to be to be + // turned off when selecting other stereoscopy modes. + if (g_Config.sPostProcessingShader == "dubois") + { + g_Config.sPostProcessingShader = ""; + } + g_Config.iStereoMode = STEREO_SBS; + } + else + { + g_Config.iStereoMode = STEREO_OFF; + } + } + if (IsHotkey(HK_TOGGLE_STEREO_TAB)) + { + if (g_Config.iStereoMode != STEREO_TAB) + { + if (g_Config.sPostProcessingShader == "dubois") + { + g_Config.sPostProcessingShader = ""; + } + g_Config.iStereoMode = STEREO_TAB; + } + else + { + g_Config.iStereoMode = STEREO_OFF; + } + } + if (IsHotkey(HK_TOGGLE_STEREO_ANAGLYPH)) + { + if (g_Config.iStereoMode != STEREO_ANAGLYPH) + { + // Setting the anaglyph mode also requires a specific + // post-processing shader to be activated. + g_Config.iStereoMode = STEREO_ANAGLYPH; + g_Config.sPostProcessingShader = "dubois"; + } + else + { + g_Config.iStereoMode = STEREO_OFF; + g_Config.sPostProcessingShader = ""; + } + } + if (IsHotkey(HK_TOGGLE_STEREO_3DVISION)) + { + if (g_Config.iStereoMode != STEREO_3DVISION) + { + if (g_Config.sPostProcessingShader == "dubois") + { + g_Config.sPostProcessingShader = ""; + } + g_Config.iStereoMode = STEREO_3DVISION; + } + else + { + g_Config.iStereoMode = STEREO_OFF; + } + } + auto savePreset = [](const std::string& param, int value) { IniFile localIni = SConfig::GetInstance().LoadLocalGameIni(); |
