mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-24 14:49:42 -06:00
VideoConfigDiag: Add stereoscopy options group.
This commit is contained in:
@ -73,7 +73,7 @@ FramebufferManager::FramebufferManager(int targetWidth, int targetHeight, int ms
|
||||
m_efbDepth = glObj[1];
|
||||
m_efbColorSwap = glObj[2];
|
||||
|
||||
m_EFBLayers = (g_ActiveConfig.bStereo) ? 2 : 1;
|
||||
m_EFBLayers = (g_ActiveConfig.iStereoMode > 0) ? 2 : 1;
|
||||
|
||||
// OpenGL MSAA textures are a different kind of texture type and must be allocated
|
||||
// with a different function, so we create them separately.
|
||||
|
@ -200,7 +200,7 @@ SHADER* ProgramShaderCache::SetShader(DSTALPHA_MODE dstAlphaMode, u32 components
|
||||
ShaderCode gcode;
|
||||
GenerateVertexShaderCode(vcode, components, API_OPENGL);
|
||||
GeneratePixelShaderCode(pcode, dstAlphaMode, API_OPENGL, components);
|
||||
if (g_ActiveConfig.bStereo)
|
||||
if (g_ActiveConfig.iStereoMode > 0)
|
||||
GenerateGeometryShaderCode(gcode, components, API_OPENGL);
|
||||
|
||||
if (g_ActiveConfig.bEnableShaderDebugging)
|
||||
|
@ -599,7 +599,7 @@ Renderer::Renderer()
|
||||
s_LastMultisampleMode = g_ActiveConfig.iMultisampleMode;
|
||||
s_MSAASamples = GetNumMSAASamples(s_LastMultisampleMode);
|
||||
ApplySSAASettings();
|
||||
s_LastStereo = g_ActiveConfig.bStereo;
|
||||
s_LastStereo = g_ActiveConfig.iStereoMode > 0;
|
||||
|
||||
// Decide framebuffer size
|
||||
s_backbuffer_width = (int)GLInterface->GetBackBufferWidth();
|
||||
@ -1514,7 +1514,7 @@ void Renderer::SwapImpl(u32 xfbAddr, u32 fbWidth, u32 fbStride, u32 fbHeight, co
|
||||
|
||||
sourceRc.right -= fbStride - fbWidth;
|
||||
|
||||
if (g_ActiveConfig.bStereo)
|
||||
if (g_ActiveConfig.iStereoMode == 1)
|
||||
{
|
||||
TargetRectangle leftRc = drawRc, rightRc = drawRc;
|
||||
int width = drawRc.right - drawRc.left;
|
||||
@ -1537,7 +1537,7 @@ void Renderer::SwapImpl(u32 xfbAddr, u32 fbWidth, u32 fbStride, u32 fbHeight, co
|
||||
// for msaa mode, we must resolve the efb content to non-msaa
|
||||
GLuint tex = FramebufferManager::ResolveAndGetRenderTarget(rc);
|
||||
|
||||
if (g_ActiveConfig.bStereo)
|
||||
if (g_ActiveConfig.iStereoMode == 1)
|
||||
{
|
||||
TargetRectangle leftRc = flipped_trc, rightRc = flipped_trc;
|
||||
int width = flipped_trc.right - flipped_trc.left;
|
||||
@ -1699,16 +1699,16 @@ void Renderer::SwapImpl(u32 xfbAddr, u32 fbWidth, u32 fbStride, u32 fbHeight, co
|
||||
s_LastEFBScale = g_ActiveConfig.iEFBScale;
|
||||
}
|
||||
|
||||
if (xfbchanged || WindowResized || (s_LastMultisampleMode != g_ActiveConfig.iMultisampleMode) || (s_LastStereo != g_ActiveConfig.bStereo))
|
||||
if (xfbchanged || WindowResized || (s_LastMultisampleMode != g_ActiveConfig.iMultisampleMode) || (s_LastStereo != (g_ActiveConfig.iStereoMode > 0)))
|
||||
{
|
||||
UpdateDrawRectangle(s_backbuffer_width, s_backbuffer_height);
|
||||
|
||||
if (CalculateTargetSize(s_backbuffer_width, s_backbuffer_height) || s_LastMultisampleMode != g_ActiveConfig.iMultisampleMode || s_LastStereo != g_ActiveConfig.bStereo)
|
||||
if (CalculateTargetSize(s_backbuffer_width, s_backbuffer_height) || s_LastMultisampleMode != g_ActiveConfig.iMultisampleMode || s_LastStereo != (g_ActiveConfig.iStereoMode > 0))
|
||||
{
|
||||
s_LastMultisampleMode = g_ActiveConfig.iMultisampleMode;
|
||||
s_MSAASamples = GetNumMSAASamples(s_LastMultisampleMode);
|
||||
ApplySSAASettings();
|
||||
s_LastStereo = g_ActiveConfig.bStereo;
|
||||
s_LastStereo = g_ActiveConfig.iStereoMode > 0;
|
||||
|
||||
delete g_framebuffer_manager;
|
||||
g_framebuffer_manager = new FramebufferManager(s_target_width, s_target_height,
|
||||
|
@ -364,7 +364,7 @@ TextureCache::TextureCache()
|
||||
" ocol0 = texcol * mat4(colmat[0], colmat[1], colmat[2], colmat[3]) + colmat[4];\n"
|
||||
"}\n";
|
||||
|
||||
const char *VProgram = (g_ActiveConfig.bStereo) ?
|
||||
const char *VProgram = (g_ActiveConfig.iStereoMode > 0) ?
|
||||
"out vec2 v_uv0;\n"
|
||||
"SAMPLER_BINDING(9) uniform sampler2DArray samp9;\n"
|
||||
"uniform vec4 copy_position;\n" // left, top, right, bottom
|
||||
@ -385,7 +385,7 @@ TextureCache::TextureCache()
|
||||
" gl_Position = vec4(rawpos*2.0-1.0, 0.0, 1.0);\n"
|
||||
"}\n";
|
||||
|
||||
const char *GProgram = (g_ActiveConfig.bStereo) ?
|
||||
const char *GProgram = (g_ActiveConfig.iStereoMode > 0) ?
|
||||
"layout(triangles) in;\n"
|
||||
"layout(triangle_strip, max_vertices = 6) out;\n"
|
||||
"in vec2 v_uv0[];\n"
|
||||
|
Reference in New Issue
Block a user