summaryrefslogtreecommitdiff
path: root/indra/newview/app_settings/shaders/class1/windlight
diff options
context:
space:
mode:
authorRunitai Linden <davep@lindenlab.com>2020-03-05 16:28:06 -0600
committerRunitai Linden <davep@lindenlab.com>2020-03-05 16:28:06 -0600
commit7c7d71269f5b47397d14bbe44e341e4ac1d96889 (patch)
treeea9ff1c27a6e067d225929b2f28d637db32d20bf /indra/newview/app_settings/shaders/class1/windlight
parent90ad38db065877be16371e7814a39618135a30ab (diff)
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.
Diffstat (limited to 'indra/newview/app_settings/shaders/class1/windlight')
-rw-r--r--indra/newview/app_settings/shaders/class1/windlight/atmosphericsFuncs.glsl3
1 files changed, 2 insertions, 1 deletions
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;