From 0a0cfcf2ef92375f099ed91f009db1ebf2d410c0 Mon Sep 17 00:00:00 2001 From: Runitai Linden Date: Fri, 13 Mar 2020 12:58:47 -0500 Subject: SL-12233 Fix for disagreement between fullbright implementations with ALM on and off. --- .../app_settings/shaders/class3/windlight/transportF.glsl | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'indra/newview/app_settings/shaders/class3') diff --git a/indra/newview/app_settings/shaders/class3/windlight/transportF.glsl b/indra/newview/app_settings/shaders/class3/windlight/transportF.glsl index 18705f785f..aa7dbc39ce 100644 --- a/indra/newview/app_settings/shaders/class3/windlight/transportF.glsl +++ b/indra/newview/app_settings/shaders/class3/windlight/transportF.glsl @@ -49,10 +49,15 @@ vec3 atmosTransport(vec3 light) return atmosTransportFrag(light, getAdditiveColor(), getAtmosAttenuation()); } -vec3 fullbrightAtmosTransport(vec3 light) +vec3 fullbrightAtmosTransportFrag(vec3 light, vec3 additive, vec3 atten) { float brightness = dot(light.rgb, vec3(0.33333)); - return atmosTransportFrag(light * 0.5, getAdditiveColor() * (brightness * 0.5 + 0.5), getAtmosAttenuation()); + return atmosTransportFrag(light * 0.5, additive * (brightness * 0.5 + 0.5), atten); +} + +vec3 fullbrightAtmosTransport(vec3 light) +{ + return atmosTransportFrag(light, getAdditiveColor(), getAtmosAttenuation()); } vec3 fullbrightShinyAtmosTransport(vec3 light) -- cgit v1.2.3