diff options
author | Dave Houlton <euclid@lindenlab.com> | 2020-09-17 16:15:29 +0000 |
---|---|---|
committer | Dave Houlton <euclid@lindenlab.com> | 2020-09-17 16:15:29 +0000 |
commit | 4837def8d74df3dad6577d7d19163891040c054d (patch) | |
tree | 702df1071765973e531c1be445fd882907f18437 /indra/newview/app_settings/shaders/class2 | |
parent | c0bbac0676e428bba5020e4c3a156edd63045a86 (diff) | |
parent | e8f4017b910ae6276772f540eef80ac0c788cb57 (diff) |
Merged in euclid-misc (pull request #305)
DRTVWR-4976 Misc shader cleanup.
Approved-by: Michael Pohoreski
Diffstat (limited to 'indra/newview/app_settings/shaders/class2')
-rw-r--r-- | indra/newview/app_settings/shaders/class2/windlight/cloudsV.glsl | 4 | ||||
-rw-r--r-- | indra/newview/app_settings/shaders/class2/windlight/skyV.glsl | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/indra/newview/app_settings/shaders/class2/windlight/cloudsV.glsl b/indra/newview/app_settings/shaders/class2/windlight/cloudsV.glsl index 75e074cbf8..1f881eb44b 100644 --- a/indra/newview/app_settings/shaders/class2/windlight/cloudsV.glsl +++ b/indra/newview/app_settings/shaders/class2/windlight/cloudsV.glsl @@ -99,12 +99,12 @@ void main() // fade clouds beyond a certain point so the bottom of the sky dome doesn't look silly at high altitude altitude_blend_factor = clamp((rel_pos.y + 512.0) / max_y, 0.0, 1.0); - // Set altitude + // Adj position vector to clamp altitude if (rel_pos.y > 0.) { rel_pos *= (max_y / rel_pos.y); } - else + if (rel_pos.y < 0.) { rel_pos *= (-32000. / rel_pos.y); } diff --git a/indra/newview/app_settings/shaders/class2/windlight/skyV.glsl b/indra/newview/app_settings/shaders/class2/windlight/skyV.glsl index 6528066a4e..a0a33b8642 100644 --- a/indra/newview/app_settings/shaders/class2/windlight/skyV.glsl +++ b/indra/newview/app_settings/shaders/class2/windlight/skyV.glsl @@ -67,12 +67,12 @@ void main() // Get relative position vec3 rel_pos = position.xyz - camPosLocal.xyz + vec3(0, 50, 0); - // Set altitude + // Adj position vector to clamp altitude if (rel_pos.y > 0.) { rel_pos *= (max_y / rel_pos.y); } - else + if (rel_pos.y < 0.) { rel_pos *= (-32000. / rel_pos.y); } |