From 2c56ccef1818ce06ae330b9aafe6519a409047bd Mon Sep 17 00:00:00 2001 From: "Unknown W. Brackets" Date: Sat, 26 Oct 2013 02:19:02 -0700 Subject: [PATCH] Make sure frag shader ID matches generated code. Before, we would use an id with alphatest on, but not actually compile in alphatest. Or, we would use a shader with alphatest, when we actually could compile it out. --- GPU/GLES/FragmentShaderGenerator.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/GPU/GLES/FragmentShaderGenerator.cpp b/GPU/GLES/FragmentShaderGenerator.cpp index 94d76e8a9..1e7c83024 100644 --- a/GPU/GLES/FragmentShaderGenerator.cpp +++ b/GPU/GLES/FragmentShaderGenerator.cpp @@ -176,10 +176,10 @@ void ComputeFragmentShaderID(FragmentShaderID *id) { } id->d[0] |= (lmode & 1) << 7; - id->d[0] |= gstate.isAlphaTestEnabled() << 8; + id->d[0] |= enableAlphaTest << 8; if (enableAlphaTest) id->d[0] |= gstate.getAlphaTestFunction() << 9; - id->d[0] |= gstate.isColorTestEnabled() << 12; + id->d[0] |= enableColorTest << 12; if (enableColorTest) id->d[0] |= gstate.getColorTestFunction() << 13; // color test func id->d[0] |= (enableFog & 1) << 15;