VideoConfig: Rename Separation to Depth and update descriptions.

More accurate since it's not a real IPD and Nvidia also calls it depth.
This commit is contained in:
Jules Blok 2014-12-21 14:06:16 +01:00
parent 5526b39320
commit 70b898e2c6
9 changed files with 32 additions and 30 deletions

View File

@ -81,8 +81,8 @@ static const struct
{ "FreelookZoomOut", 83 /* 'S' */, 4 /* wxMOD_SHIFT */ }, { "FreelookZoomOut", 83 /* 'S' */, 4 /* wxMOD_SHIFT */ },
{ "FreelookReset", 82 /* 'R' */, 4 /* wxMOD_SHIFT */ }, { "FreelookReset", 82 /* 'R' */, 4 /* wxMOD_SHIFT */ },
{ "IncreaseSeparation", 0, 0 /* wxMOD_NONE */ }, { "IncreaseDepth", 0, 0 /* wxMOD_NONE */ },
{ "DecreaseSeparation", 0, 0 /* wxMOD_NONE */ }, { "DecreaseDepth", 0, 0 /* wxMOD_NONE */ },
{ "IncreaseConvergence", 0, 0 /* wxMOD_NONE */ }, { "IncreaseConvergence", 0, 0 /* wxMOD_NONE */ },
{ "DecreaseConvergence", 0, 0 /* wxMOD_NONE */ }, { "DecreaseConvergence", 0, 0 /* wxMOD_NONE */ },

View File

@ -54,8 +54,8 @@ enum Hotkey
HK_FREELOOK_ZOOM_OUT, HK_FREELOOK_ZOOM_OUT,
HK_FREELOOK_RESET, HK_FREELOOK_RESET,
HK_INCREASE_SEPARATION, HK_INCREASE_DEPTH,
HK_DECREASE_SEPARATION, HK_DECREASE_DEPTH,
HK_INCREASE_CONVERGENCE, HK_INCREASE_CONVERGENCE,
HK_DECREASE_CONVERGENCE, HK_DECREASE_CONVERGENCE,

View File

@ -1123,15 +1123,15 @@ void CFrame::OnKeyDown(wxKeyEvent& event)
{ {
State::Load(g_saveSlot); State::Load(g_saveSlot);
} }
else if (IsHotkey(event, HK_INCREASE_SEPARATION)) else if (IsHotkey(event, HK_INCREASE_DEPTH))
{ {
if (++g_Config.iStereoSeparation > 100) if (++g_Config.iStereoDepth > 100)
g_Config.iStereoSeparation = 100; g_Config.iStereoDepth = 100;
} }
else if (IsHotkey(event, HK_DECREASE_SEPARATION)) else if (IsHotkey(event, HK_DECREASE_DEPTH))
{ {
if (--g_Config.iStereoSeparation < 0) if (--g_Config.iStereoDepth < 0)
g_Config.iStereoSeparation = 0; g_Config.iStereoDepth = 0;
} }
else if (IsHotkey(event, HK_INCREASE_CONVERGENCE)) else if (IsHotkey(event, HK_INCREASE_CONVERGENCE))
{ {

View File

@ -238,10 +238,10 @@ void HotkeyConfigDialog::CreateHotkeyGUIControls()
_("Freelook Zoom Out"), _("Freelook Zoom Out"),
_("Freelook Reset"), _("Freelook Reset"),
_("Increase Stereocopy Separation"), _("Increase Depth"),
_("Decrease Stereocopy Separation"), _("Decrease Depth"),
_("Increase Stereocopy Convergence"), _("Increase Convergence"),
_("Decrease Stereocopy Convergence"), _("Decrease Convergence"),
_("Load State Slot 1"), _("Load State Slot 1"),
_("Load State Slot 2"), _("Load State Slot 2"),

View File

@ -150,8 +150,8 @@ static wxString ppshader_desc = wxTRANSLATE("Apply a post-processing effect afte
static wxString cache_efb_copies_desc = wxTRANSLATE("Slightly speeds up EFB to RAM copies by sacrificing emulation accuracy.\nSometimes also increases visual quality.\nIf you're experiencing any issues, try raising texture cache accuracy or disable this option.\n\nIf unsure, leave this unchecked."); static wxString cache_efb_copies_desc = wxTRANSLATE("Slightly speeds up EFB to RAM copies by sacrificing emulation accuracy.\nSometimes also increases visual quality.\nIf you're experiencing any issues, try raising texture cache accuracy or disable this option.\n\nIf unsure, leave this unchecked.");
static wxString shader_errors_desc = wxTRANSLATE("Usually if shader compilation fails, an error message is displayed.\nHowever, one may skip the popups to allow interruption free gameplay by checking this option.\n\nIf unsure, leave this unchecked."); static wxString shader_errors_desc = wxTRANSLATE("Usually if shader compilation fails, an error message is displayed.\nHowever, one may skip the popups to allow interruption free gameplay by checking this option.\n\nIf unsure, leave this unchecked.");
static wxString stereo_3d_desc = wxTRANSLATE("Select the stereoscopic 3D mode, stereoscopy allows you to get a better feeling of depth if you have the necessary hardware.\nSide-by-Side and Top-and-Bottom are used by most 3D TVs.\nAnaglyph is used for Red-Cyan colored glasses.\nHeavily decreases emulation speed and sometimes causes issues.\n\nIf unsure, select Off."); static wxString stereo_3d_desc = wxTRANSLATE("Select the stereoscopic 3D mode, stereoscopy allows you to get a better feeling of depth if you have the necessary hardware.\nSide-by-Side and Top-and-Bottom are used by most 3D TVs.\nAnaglyph is used for Red-Cyan colored glasses.\nHeavily decreases emulation speed and sometimes causes issues.\n\nIf unsure, select Off.");
static wxString stereo_separation_desc = wxTRANSLATE("Control the separation distance, this is the distance between the virtual cameras.\nA higher value creates a stronger feeling of depth while a lower value is more comfortable."); static wxString stereo_depth_desc = wxTRANSLATE("Control the distance between the virtual cameras.\nA higher value creates a stronger feeling of depth while a lower value is more comfortable.");
static wxString stereo_convergence_desc = wxTRANSLATE("Control the convergence distance, this controls the apparant distance of virtual objects.\nA higher value creates stronger out-of-screen effects while a lower value is more comfortable."); static wxString stereo_convergence_desc = wxTRANSLATE("Control the distance of the convergence plane, this is the distance at which objects will appear to be in front of the screen.\nA higher value creates stronger out-of-screen effects while a lower value is more comfortable.");
static wxString stereo_swap_desc = wxTRANSLATE("Swap the left and right eye, mostly useful if you want to view side-by-side cross-eyed.\n\nIf unsure, leave this unchecked."); static wxString stereo_swap_desc = wxTRANSLATE("Swap the left and right eye, mostly useful if you want to view side-by-side cross-eyed.\n\nIf unsure, leave this unchecked.");
@ -457,11 +457,11 @@ VideoConfigDiag::VideoConfigDiag(wxWindow* parent, const std::string &title, con
szr_stereo->Add(new wxStaticText(page_enh, wxID_ANY, _("Stereoscopic 3D Mode:")), 1, wxALIGN_CENTER_VERTICAL, 0); szr_stereo->Add(new wxStaticText(page_enh, wxID_ANY, _("Stereoscopic 3D Mode:")), 1, wxALIGN_CENTER_VERTICAL, 0);
szr_stereo->Add(CreateChoice(page_enh, vconfig.iStereoMode, wxGetTranslation(stereo_3d_desc), vconfig.backend_info.bSupports3DVision ? 5 : 4, stereo_choices)); szr_stereo->Add(CreateChoice(page_enh, vconfig.iStereoMode, wxGetTranslation(stereo_3d_desc), vconfig.backend_info.bSupports3DVision ? 5 : 4, stereo_choices));
wxSlider* const sep_slider = new wxSlider(page_enh, wxID_ANY, vconfig.iStereoSeparation, 0, 100, wxDefaultPosition, wxDefaultSize); wxSlider* const sep_slider = new wxSlider(page_enh, wxID_ANY, vconfig.iStereoDepth, 0, 100, wxDefaultPosition, wxDefaultSize);
sep_slider->Bind(wxEVT_SLIDER, &VideoConfigDiag::Event_StereoSep, this); sep_slider->Bind(wxEVT_SLIDER, &VideoConfigDiag::Event_StereoSep, this);
RegisterControl(sep_slider, wxGetTranslation(stereo_separation_desc)); RegisterControl(sep_slider, wxGetTranslation(stereo_depth_desc));
szr_stereo->Add(new wxStaticText(page_enh, wxID_ANY, _("Separation:")), 1, wxALIGN_CENTER_VERTICAL, 0); szr_stereo->Add(new wxStaticText(page_enh, wxID_ANY, _("Depth:")), 1, wxALIGN_CENTER_VERTICAL, 0);
szr_stereo->Add(sep_slider, 0, wxEXPAND | wxRIGHT); szr_stereo->Add(sep_slider, 0, wxEXPAND | wxRIGHT);
wxSlider* const conv_slider = new wxSlider(page_enh, wxID_ANY, vconfig.iStereoConvergence, 0, 500, wxDefaultPosition, wxDefaultSize); wxSlider* const conv_slider = new wxSlider(page_enh, wxID_ANY, vconfig.iStereoConvergence, 0, 500, wxDefaultPosition, wxDefaultSize);

View File

@ -167,7 +167,7 @@ protected:
void Event_StereoSep(wxCommandEvent &ev) void Event_StereoSep(wxCommandEvent &ev)
{ {
vconfig.iStereoSeparation = ev.GetInt(); vconfig.iStereoDepth = ev.GetInt();
ev.Skip(); ev.Skip();
} }

View File

@ -52,10 +52,10 @@ void GeometryShaderManager::SetConstants()
if (xfmem.projection.type == GX_PERSPECTIVE) if (xfmem.projection.type == GX_PERSPECTIVE)
{ {
float offset = (g_ActiveConfig.iStereoSeparation / 1000.0f) * (g_ActiveConfig.iStereoSeparationPercent / 100.0f); float offset = (g_ActiveConfig.iStereoDepth / 1000.0f) * (g_ActiveConfig.iStereoDepthPercentage / 100.0f);
constants.stereoparams[0] = (g_ActiveConfig.bStereoSwapEyes) ? offset : -offset; constants.stereoparams[0] = (g_ActiveConfig.bStereoSwapEyes) ? offset : -offset;
constants.stereoparams[1] = (g_ActiveConfig.bStereoSwapEyes) ? -offset : offset; constants.stereoparams[1] = (g_ActiveConfig.bStereoSwapEyes) ? -offset : offset;
constants.stereoparams[2] = (g_ActiveConfig.iStereoConvergence / 10.0f) * (g_ActiveConfig.iStereoConvergencePercent / 100.0f); constants.stereoparams[2] = (g_ActiveConfig.iStereoConvergence / 10.0f) * (g_ActiveConfig.iStereoConvergencePercentage / 100.0f);
} }
else else
{ {

View File

@ -41,8 +41,8 @@ VideoConfig::VideoConfig()
// Game-specific stereoscopy settings // Game-specific stereoscopy settings
bStereoMonoEFBDepth = false; bStereoMonoEFBDepth = false;
iStereoSeparationPercent = 100; iStereoDepthPercentage = 100;
iStereoConvergencePercent = 100; iStereoConvergencePercentage = 100;
} }
void VideoConfig::Load(const std::string& ini_file) void VideoConfig::Load(const std::string& ini_file)
@ -88,7 +88,7 @@ void VideoConfig::Load(const std::string& ini_file)
enhancements->Get("MaxAnisotropy", &iMaxAnisotropy, 0); // NOTE - this is x in (1 << x) enhancements->Get("MaxAnisotropy", &iMaxAnisotropy, 0); // NOTE - this is x in (1 << x)
enhancements->Get("PostProcessingShader", &sPostProcessingShader, ""); enhancements->Get("PostProcessingShader", &sPostProcessingShader, "");
enhancements->Get("StereoMode", &iStereoMode, 0); enhancements->Get("StereoMode", &iStereoMode, 0);
enhancements->Get("StereoSeparation", &iStereoSeparation, 20); enhancements->Get("StereoDepth", &iStereoDepth, 20);
enhancements->Get("StereoConvergence", &iStereoConvergence, 20); enhancements->Get("StereoConvergence", &iStereoConvergence, 20);
enhancements->Get("StereoSwapEyes", &bStereoSwapEyes, false); enhancements->Get("StereoSwapEyes", &bStereoSwapEyes, false);
@ -185,13 +185,13 @@ void VideoConfig::GameIniLoad()
CHECK_SETTING("Video_Enhancements", "MaxAnisotropy", iMaxAnisotropy); // NOTE - this is x in (1 << x) CHECK_SETTING("Video_Enhancements", "MaxAnisotropy", iMaxAnisotropy); // NOTE - this is x in (1 << x)
CHECK_SETTING("Video_Enhancements", "PostProcessingShader", sPostProcessingShader); CHECK_SETTING("Video_Enhancements", "PostProcessingShader", sPostProcessingShader);
CHECK_SETTING("Video_Enhancements", "StereoMode", iStereoMode); CHECK_SETTING("Video_Enhancements", "StereoMode", iStereoMode);
CHECK_SETTING("Video_Enhancements", "StereoSeparation", iStereoSeparation); CHECK_SETTING("Video_Enhancements", "StereoDepth", iStereoDepth);
CHECK_SETTING("Video_Enhancements", "StereoConvergence", iStereoConvergence); CHECK_SETTING("Video_Enhancements", "StereoConvergence", iStereoConvergence);
CHECK_SETTING("Video_Enhancements", "StereoSwapEyes", bStereoSwapEyes); CHECK_SETTING("Video_Enhancements", "StereoSwapEyes", bStereoSwapEyes);
CHECK_SETTING("Video_Stereoscopy", "StereoMonoEFBDepth", bStereoMonoEFBDepth); CHECK_SETTING("Video_Stereoscopy", "StereoMonoEFBDepth", bStereoMonoEFBDepth);
CHECK_SETTING("Video_Stereoscopy", "StereoSeparationPercent", iStereoSeparationPercent); CHECK_SETTING("Video_Stereoscopy", "StereoDepthPercentage", iStereoDepthPercentage);
CHECK_SETTING("Video_Stereoscopy", "StereoConvergencePercent", iStereoConvergencePercent); CHECK_SETTING("Video_Stereoscopy", "StereoConvergencePercentage", iStereoConvergencePercentage);
CHECK_SETTING("Video_Hacks", "EFBAccessEnable", bEFBAccessEnable); CHECK_SETTING("Video_Hacks", "EFBAccessEnable", bEFBAccessEnable);
CHECK_SETTING("Video_Hacks", "EFBCopyEnable", bEFBCopyEnable); CHECK_SETTING("Video_Hacks", "EFBCopyEnable", bEFBCopyEnable);
@ -267,7 +267,7 @@ void VideoConfig::Save(const std::string& ini_file)
enhancements->Set("MaxAnisotropy", iMaxAnisotropy); enhancements->Set("MaxAnisotropy", iMaxAnisotropy);
enhancements->Set("PostProcessingShader", sPostProcessingShader); enhancements->Set("PostProcessingShader", sPostProcessingShader);
enhancements->Set("StereoMode", iStereoMode); enhancements->Set("StereoMode", iStereoMode);
enhancements->Set("StereoSeparation", iStereoSeparation); enhancements->Set("StereoDepth", iStereoDepth);
enhancements->Set("StereoConvergence", iStereoConvergence); enhancements->Set("StereoConvergence", iStereoConvergence);
enhancements->Set("StereoSwapEyes", bStereoSwapEyes); enhancements->Set("StereoSwapEyes", bStereoSwapEyes);

View File

@ -81,7 +81,7 @@ struct VideoConfig final
int iMaxAnisotropy; int iMaxAnisotropy;
std::string sPostProcessingShader; std::string sPostProcessingShader;
int iStereoMode; int iStereoMode;
int iStereoSeparation; int iStereoDepth;
int iStereoConvergence; int iStereoConvergence;
bool bStereoSwapEyes; bool bStereoSwapEyes;
@ -129,6 +129,8 @@ struct VideoConfig final
bool bStereoMonoEFBDepth; bool bStereoMonoEFBDepth;
int iStereoSeparationPercent; int iStereoSeparationPercent;
int iStereoConvergencePercent; int iStereoConvergencePercent;
int iStereoDepthPercentage;
int iStereoConvergencePercentage;
// D3D only config, mostly to be merged into the above // D3D only config, mostly to be merged into the above
int iAdapter; int iAdapter;