From b143aa96fcd6d16558464c98bcfd9984f7d29750 Mon Sep 17 00:00:00 2001 From: Graham Linden Date: Mon, 13 May 2019 15:33:48 -0700 Subject: SL-10856 Modify calc of sunlight to avoid clipping in gamma correct on values outside 0-1 range. Modify shaders to put back ambient clamp tuned to be close to ambient contrib in low/mid lighting. --- indra/newview/app_settings/shaders/class2/deferred/softenLightF.glsl | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'indra/newview/app_settings/shaders/class2/deferred') diff --git a/indra/newview/app_settings/shaders/class2/deferred/softenLightF.glsl b/indra/newview/app_settings/shaders/class2/deferred/softenLightF.glsl index e41b4b99a3..39b13b46cc 100644 --- a/indra/newview/app_settings/shaders/class2/deferred/softenLightF.glsl +++ b/indra/newview/app_settings/shaders/class2/deferred/softenLightF.glsl @@ -116,8 +116,7 @@ void main() float ambient = da; ambient *= 0.5; ambient *= ambient; - //ambient = max(getAmbientClamp(), ambient); - ambient = 1.0 - ambient; + ambient = min(getAmbientClamp(), 1.0 - ambient); vec3 sun_contrib = min(scol, final_da) * sunlit; -- cgit v1.2.3