From 2408e8be5ee66d8860cd7a8275012af1fa5635a6 Mon Sep 17 00:00:00 2001 From: Graham Linden Date: Wed, 5 Jun 2019 09:15:19 -0700 Subject: SL-11357 Nerf moisture and ice levels iff there's no sun or moon to generate light to refract. --- indra/newview/lldrawpoolwlsky.cpp | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'indra/newview') diff --git a/indra/newview/lldrawpoolwlsky.cpp b/indra/newview/lldrawpoolwlsky.cpp index b9bc7678e6..968607de5d 100644 --- a/indra/newview/lldrawpoolwlsky.cpp +++ b/indra/newview/lldrawpoolwlsky.cpp @@ -185,6 +185,13 @@ void LLDrawPoolWLSky::renderSkyHazeDeferred(const LLVector3& camPosLocal, F32 ca F32 droplet_radius = (float)psky->getSkyDropletRadius(); F32 ice_level = (float)psky->getSkyIceLevel(); + // hobble halos and rainbows when there's no light source to generate them + if (!psky->getIsSunUp() && !psky->getIsMoonUp()) + { + moisture_level = 0.0f; + ice_level = 0.0f; + } + sky_shader->uniform1f(LLShaderMgr::MOISTURE_LEVEL, moisture_level); sky_shader->uniform1f(LLShaderMgr::DROPLET_RADIUS, droplet_radius); sky_shader->uniform1f(LLShaderMgr::ICE_LEVEL, ice_level); -- cgit v1.2.3