summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon
diff options
context:
space:
mode:
authorNeoBrainX <NeoBrainX@gmail.com>2013-06-29 22:54:19 +0200
committerNeoBrainX <NeoBrainX@gmail.com>2013-06-29 23:01:42 +0200
commitf524312fd17e62cbc761bb01953c67763fc9242b (patch)
tree9691c7a7730c03e3ca315ab019e54bea01d3ab76 /Source/Core/VideoCommon
parent1083d78721e896f55d816aab686c49735d235fd8 (diff)
VertexShaderGen: Fix a potential bug where vertex shader uids don't change when pixel lighting is toggled.
Diffstat (limited to 'Source/Core/VideoCommon')
-rw-r--r--Source/Core/VideoCommon/Src/VertexShaderGen.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/Core/VideoCommon/Src/VertexShaderGen.cpp b/Source/Core/VideoCommon/Src/VertexShaderGen.cpp
index 81d45cd6ad..4296f42930 100644
--- a/Source/Core/VideoCommon/Src/VertexShaderGen.cpp
+++ b/Source/Core/VideoCommon/Src/VertexShaderGen.cpp
@@ -279,8 +279,8 @@ static void GenerateVertexShader(T& out, u32 components, API_TYPE api_type)
out.Write("o.colors_0 = float4(1.0f, 1.0f, 1.0f, 1.0f);\n");
}
- // TODO: This probably isn't necessary if pixel lighting is enabled.
- GenerateLightingShader<T>(out, uid_data.lighting, components, I_MATERIALS, I_LIGHTS, "color", "o.colors_");
+ if (g_ActiveConfig.bEnablePixelLighting && g_ActiveConfig.backend_info.bSupportsPixelLighting)
+ GenerateLightingShader<T>(out, uid_data.lighting, components, I_MATERIALS, I_LIGHTS, "color", "o.colors_");
if (xfregs.numChan.numColorChans < 2)
{