mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-28 11:49:06 +00:00
VideoCommon: Add a separate constants buffer for the geometry shader.
This commit is contained in:
parent
21ac9aa715
commit
b406e4e1f2
19 changed files with 189 additions and 23 deletions
|
@ -512,18 +512,6 @@ void VertexShaderManager::SetConstants()
|
|||
memcpy(constants.projection, correctedMtx.data, 4*16);
|
||||
}
|
||||
|
||||
if (g_ActiveConfig.iStereoMode > 0 && xfmem.projection.type == GX_PERSPECTIVE)
|
||||
{
|
||||
float offset = (g_ActiveConfig.iStereoSeparation / 1000.0f) * (g_ActiveConfig.iStereoSeparationPercent / 100.0f);
|
||||
constants.stereoparams[0] = (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);
|
||||
}
|
||||
else
|
||||
{
|
||||
constants.stereoparams[0] = constants.stereoparams[1] = 0;
|
||||
}
|
||||
|
||||
dirty = true;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue