summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGuilherme Souza <gdsdsilva@inf.ufpel.edu.br>2019-05-06 10:52:48 -0300
committerGuilherme Souza <gdsdsilva@inf.ufpel.edu.br>2019-05-07 12:42:28 -0300
commitb363125568690d85290c607d7661dacd6cbfb3a0 (patch)
treee819e30a488e49034a2ff7ff34495564552a70d3
parentfcbadd4334d4e2c11919fbe543dbd3ee825836d4 (diff)
Fix SHADOWS_DISABLED flag in GLES2
Signed-off-by: Guilherme Souza <gdsdsilva@inf.ufpel.edu.br>
-rw-r--r--drivers/gles2/shaders/scene.glsl12
1 files changed, 12 insertions, 0 deletions
diff --git a/drivers/gles2/shaders/scene.glsl b/drivers/gles2/shaders/scene.glsl
index 1c35b455c4..e7e84c4091 100644
--- a/drivers/gles2/shaders/scene.glsl
+++ b/drivers/gles2/shaders/scene.glsl
@@ -1699,6 +1699,8 @@ FRAGMENT_SHADER_CODE
#endif
+#if !defined(SHADOWS_DISABLED)
+
#ifdef USE_SHADOW
{
highp vec4 splane = shadow_coord;
@@ -1729,6 +1731,8 @@ FRAGMENT_SHADER_CODE
}
#endif
+#endif //SHADOWS_DISABLED
+
#endif //type omni
#ifdef LIGHT_MODE_DIRECTIONAL
@@ -1739,6 +1743,8 @@ FRAGMENT_SHADER_CODE
#endif
float depth_z = -vertex.z;
+#if !defined(SHADOWS_DISABLED)
+
#ifdef USE_SHADOW
#ifdef USE_VERTEX_LIGHTING
@@ -1957,6 +1963,8 @@ FRAGMENT_SHADER_CODE
#endif //use shadow
+#endif // SHADOWS_DISABLED
+
#endif
#ifdef LIGHT_MODE_SPOT
@@ -1993,6 +2001,8 @@ FRAGMENT_SHADER_CODE
#endif
+#if !defined(SHADOWS_DISABLED)
+
#ifdef USE_SHADOW
{
highp vec4 splane = shadow_coord;
@@ -2002,6 +2012,8 @@ FRAGMENT_SHADER_CODE
}
#endif
+#endif // SHADOWS_DISABLED
+
#endif // LIGHT_MODE_SPOT
#ifdef USE_VERTEX_LIGHTING