summaryrefslogtreecommitdiff
path: root/indra/newview/app_settings/shaders/class2/deferred
diff options
context:
space:
mode:
authorGraham Linden <graham@lindenlab.com>2019-06-18 10:40:54 -0700
committerGraham Linden <graham@lindenlab.com>2019-06-18 10:40:54 -0700
commit9d138b1440fc68d5f4b687fbf4e8635d6d2bdfe5 (patch)
tree0ed8e2782b26f967a9564c438f74eefbbd28f35a /indra/newview/app_settings/shaders/class2/deferred
parentc1a586d7e459858d31ad1549a79294832dd8e62e (diff)
Fix sky atmospherics in class1 to match class2 and Mid.
Diffstat (limited to 'indra/newview/app_settings/shaders/class2/deferred')
-rw-r--r--indra/newview/app_settings/shaders/class2/deferred/skyF.glsl7
1 files changed, 4 insertions, 3 deletions
diff --git a/indra/newview/app_settings/shaders/class2/deferred/skyF.glsl b/indra/newview/app_settings/shaders/class2/deferred/skyF.glsl
index 0f33bac3c6..889a989985 100644
--- a/indra/newview/app_settings/shaders/class2/deferred/skyF.glsl
+++ b/indra/newview/app_settings/shaders/class2/deferred/skyF.glsl
@@ -165,6 +165,8 @@ void main()
+ (haze_horizon * haze_weight) * (sunlight * temp2.x + ambient_color)
);
+ // Final atmosphere additive
+ color *= (1. - temp1);
// Increase ambient when there are more clouds
vec4 tmpAmbient = ambient_color;
@@ -178,8 +180,7 @@ void main()
+ (haze_horizon * haze_weight) * (sunlight * temp2.x + tmpAmbient)
);
- // Final atmosphere additive
- color *= (1. - temp1);
+
// Attenuate cloud color by atmosphere
temp1 = sqrt(temp1); //less atmos opacity (more transparency) below clouds
@@ -201,6 +202,6 @@ void main()
/// Gamma correct for WL (soft clip effect).
frag_data[0] = vec4(color.rgb, 1.0);
frag_data[1] = vec4(0.0,0.0,0.0,0.0);
- frag_data[2] = vec4(0.5,0.5,0.0,1.0); //1.0 in norm.w masks off fog
+ frag_data[2] = vec4(0.0,0.0,0.0,1.0); //1.0 in norm.w masks off fog
}