From 8545b81a32e1f8a7621ca7e136a5899545a5788b Mon Sep 17 00:00:00 2001 From: Ptolemy Date: Fri, 24 Jan 2020 16:30:48 -0800 Subject: SL-11406: Fix specularity being blown out due to previous fix --- .../newview/app_settings/shaders/class1/deferred/materialF.glsl | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl b/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl index 8ed5713e22..8a6b2b7066 100644 --- a/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl +++ b/indra/newview/app_settings/shaders/class1/deferred/materialF.glsl @@ -290,9 +290,7 @@ void main() // OR // adjust the final color via: // final_color *= 0.666666; - // We remap the environment intensity to closely simulate what non-EEP is doing. - // At midnight the brightness is exact. - // At midday the brightness is very close. + // We don't remap the environment intensity but adjust the final color to closely simulate what non-EEP is doing. vec4 final_normal = vec4(abnormal, env_intensity, 0.0); vec3 color = vec3(0.0); @@ -301,9 +299,8 @@ void main() if (emissive_brightness >= 1.0) { #ifdef HAS_SPECULAR_MAP - float ei = env_intensity*0.5 + 0.5; - final_normal = vec4(abnormal, ei, 0.0); - + // Note: We actually need to adjust all 4 channels not just .rgb + final_color *= 0.666666; #endif color.rgb = final_color.rgb; al = vertex_color.a; -- cgit v1.2.3