diff options
Diffstat (limited to 'indra/newview/app_settings/shaders/class2/deferred/sunLightF.glsl')
-rw-r--r-- | indra/newview/app_settings/shaders/class2/deferred/sunLightF.glsl | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/indra/newview/app_settings/shaders/class2/deferred/sunLightF.glsl b/indra/newview/app_settings/shaders/class2/deferred/sunLightF.glsl index 8abdeae5ae..e1cbfcce1a 100644 --- a/indra/newview/app_settings/shaders/class2/deferred/sunLightF.glsl +++ b/indra/newview/app_settings/shaders/class2/deferred/sunLightF.glsl @@ -53,8 +53,11 @@ void main() vec4 pos = getPosition(pos_screen); vec3 norm = getNorm(pos_screen); - frag_color.r = sampleDirectionalShadow(pos.xyz, norm, pos_screen); - frag_color.g = 1.0f; - frag_color.b = sampleSpotShadow(pos.xyz, norm, 0, pos_screen); - frag_color.a = sampleSpotShadow(pos.xyz, norm, 1, pos_screen); + vec4 col; + col.r = sampleDirectionalShadow(pos.xyz, norm, pos_screen); + col.g = 1.0f; + col.b = sampleSpotShadow(pos.xyz, norm, 0, pos_screen); + col.a = sampleSpotShadow(pos.xyz, norm, 1, pos_screen); + + frag_color = clamp(col, vec4(0), vec4(1)); } |