diff options
Diffstat (limited to 'Source/Core/VideoCommon/Src/VertexShaderManager.cpp')
| -rw-r--r-- | Source/Core/VideoCommon/Src/VertexShaderManager.cpp | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/Source/Core/VideoCommon/Src/VertexShaderManager.cpp b/Source/Core/VideoCommon/Src/VertexShaderManager.cpp index 6ad877318f..c251ddc732 100644 --- a/Source/Core/VideoCommon/Src/VertexShaderManager.cpp +++ b/Source/Core/VideoCommon/Src/VertexShaderManager.cpp @@ -184,7 +184,7 @@ void VertexShaderManager::Dirty() // TODO: A cleaner way to control the matricies without making a mess in the parameters field void VertexShaderManager::SetConstants() { - if (nTransformMatricesChanged[0] >= 0) + if (nTransformMatricesChanged[0] >= 0 || g_ActiveConfig.bUseGLSL) { int startn = nTransformMatricesChanged[0] / 4; int endn = (nTransformMatricesChanged[1] + 3) / 4; @@ -192,7 +192,7 @@ void VertexShaderManager::SetConstants() SetMultiVSConstant4fv(C_TRANSFORMMATRICES + startn, endn - startn, pstart); nTransformMatricesChanged[0] = nTransformMatricesChanged[1] = -1; } - if (nNormalMatricesChanged[0] >= 0) + if (nNormalMatricesChanged[0] >= 0 || g_ActiveConfig.bUseGLSL) { int startn = nNormalMatricesChanged[0] / 3; int endn = (nNormalMatricesChanged[1] + 2) / 3; @@ -201,7 +201,7 @@ void VertexShaderManager::SetConstants() nNormalMatricesChanged[0] = nNormalMatricesChanged[1] = -1; } - if (nPostTransformMatricesChanged[0] >= 0) + if (nPostTransformMatricesChanged[0] >= 0 || g_ActiveConfig.bUseGLSL) { int startn = nPostTransformMatricesChanged[0] / 4; int endn = (nPostTransformMatricesChanged[1] + 3 ) / 4; @@ -209,7 +209,7 @@ void VertexShaderManager::SetConstants() SetMultiVSConstant4fv(C_POSTTRANSFORMMATRICES + startn, endn - startn, pstart); } - if (nLightsChanged[0] >= 0) + if (nLightsChanged[0] >= 0 || g_ActiveConfig.bUseGLSL) { // lights don't have a 1 to 1 mapping, the color component needs to be converted to 4 floats int istart = nLightsChanged[0] / 0x10; @@ -245,14 +245,14 @@ void VertexShaderManager::SetConstants() nLightsChanged[0] = nLightsChanged[1] = -1; } - if (nMaterialsChanged) + if (nMaterialsChanged || g_ActiveConfig.bUseGLSL) { float GC_ALIGNED16(material[4]); float NormalizationCoef = 1 / 255.0f; for (int i = 0; i < 4; ++i) { - if (nMaterialsChanged & (1 << i)) + if (nMaterialsChanged & (1 << i) || g_ActiveConfig.bUseGLSL) { u32 data = *(xfregs.ambColor + i); @@ -268,7 +268,7 @@ void VertexShaderManager::SetConstants() nMaterialsChanged = 0; } - if (bPosNormalMatrixChanged) + if (bPosNormalMatrixChanged || g_ActiveConfig.bUseGLSL) { bPosNormalMatrixChanged = false; @@ -279,7 +279,7 @@ void VertexShaderManager::SetConstants() SetMultiVSConstant3fv(C_POSNORMALMATRIX + 3, 3, norm); } - if (bTexMatricesChanged[0]) + if (bTexMatricesChanged[0] || g_ActiveConfig.bUseGLSL) { bTexMatricesChanged[0] = false; const float *fptrs[] = @@ -294,7 +294,7 @@ void VertexShaderManager::SetConstants() } } - if (bTexMatricesChanged[1]) + if (bTexMatricesChanged[1] || g_ActiveConfig.bUseGLSL) { bTexMatricesChanged[1] = false; const float *fptrs[] = { @@ -308,7 +308,7 @@ void VertexShaderManager::SetConstants() } } - if (bViewportChanged) + if (bViewportChanged || g_ActiveConfig.bUseGLSL) { bViewportChanged = false; SetVSConstant4f(C_DEPTHPARAMS, @@ -321,7 +321,7 @@ void VertexShaderManager::SetConstants() bProjectionChanged = true; } - if (bProjectionChanged) + if (bProjectionChanged || g_ActiveConfig.bUseGLSL) { bProjectionChanged = false; |
