From 7c7d71269f5b47397d14bbe44e341e4ac1d96889 Mon Sep 17 00:00:00 2001 From: Runitai Linden Date: Thu, 5 Mar 2020 16:28:06 -0600 Subject: WIP - Windlight sun lighting should happen in sRGB space, not linear space. This keeps ambient from getting overblown and better matches environment lighting with ALM on/off. --- .../app_settings/shaders/class1/windlight/atmosphericsFuncs.glsl | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'indra/newview/app_settings/shaders/class1/windlight') diff --git a/indra/newview/app_settings/shaders/class1/windlight/atmosphericsFuncs.glsl b/indra/newview/app_settings/shaders/class1/windlight/atmosphericsFuncs.glsl index e5f1e11180..dcb02bd1c1 100644 --- a/indra/newview/app_settings/shaders/class1/windlight/atmosphericsFuncs.glsl +++ b/indra/newview/app_settings/shaders/class1/windlight/atmosphericsFuncs.glsl @@ -46,6 +46,7 @@ float getAmbientClamp() return 1.0f; } + void calcAtmosphericVars(vec3 inPositionEye, vec3 light_dir, float ambFactor, out vec3 sunlit, out vec3 amblit, out vec3 additive, out vec3 atten, bool use_ao) { vec3 P = inPositionEye; @@ -123,7 +124,7 @@ void calcAtmosphericVars(vec3 inPositionEye, vec3 light_dir, float ambFactor, ou temp2.x *= sun_moon_glow_factor; vec4 amb_color = ambient_color; - + //increase ambient when there are more clouds vec4 tmpAmbient = amb_color + (vec4(1.) - amb_color) * cloud_shadow * 0.5; -- cgit v1.2.3