diff options
author | Juan Linietsky <red@kyoko> | 2015-04-01 12:23:13 -0300 |
---|---|---|
committer | Juan Linietsky <red@kyoko> | 2015-04-01 12:23:13 -0300 |
commit | 76c2b9d812aad7149dad36e22eee627509feeefd (patch) | |
tree | df33d6ce3e7a4db28e88a073d4afd74dda8550eb /drivers/gles2 | |
parent | 3920c497b3811b3c0c970631599c13025c81ff14 (diff) |
fix shadow attenuation
Diffstat (limited to 'drivers/gles2')
-rw-r--r-- | drivers/gles2/shaders/canvas.glsl | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/drivers/gles2/shaders/canvas.glsl b/drivers/gles2/shaders/canvas.glsl index afa58b7741..12ff43479b 100644 --- a/drivers/gles2/shaders/canvas.glsl +++ b/drivers/gles2/shaders/canvas.glsl @@ -297,7 +297,7 @@ LIGHT_SHADER_CODE su=s.x*0.5+0.5; sz=s.z*0.5+0.5; - highp float shadow_attenuation; + highp float shadow_attenuation=0.0; #ifdef USE_DEPTH_SHADOWS @@ -314,7 +314,6 @@ LIGHT_SHADER_CODE #ifdef SHADOW_PCF5 - shadow_attenuation=0.0; shadow_attenuation += SHADOW_DEPTH(shadow_texture,vec2(su,sh))<sz?0.0:1.0; shadow_attenuation += SHADOW_DEPTH(shadow_texture,vec2(su+shadowpixel_size,sh))<sz?0.0:1.0; shadow_attenuation += SHADOW_DEPTH(shadow_texture,vec2(su+shadowpixel_size*2.0,sh))<sz?0.0:1.0; |