diff options
author | Graham Linden <graham@lindenlab.com> | 2019-02-06 16:42:23 -0800 |
---|---|---|
committer | Graham Linden <graham@lindenlab.com> | 2019-02-06 16:42:23 -0800 |
commit | 8890c3238ab4ae8bbf1bc123284f9c6d4db4f9d6 (patch) | |
tree | 6d250b8114eb4d39a7c5810813a06d730665372b /indra/newview/lldrawpoolterrain.cpp | |
parent | f8171a909cb2a18fcca47f6a0317919ece802aef (diff) |
SL-10478
Fix side-effects of having both sun and moon as potential directional light contributors.
We pass an int to the shader indicating which to prefer instead of making per-pixel decisions
and pass the moonlight color/di independently.
Obsolete llsettingssky fade color which was unused elsewhere and cached for no reason.
Diffstat (limited to 'indra/newview/lldrawpoolterrain.cpp')
-rw-r--r-- | indra/newview/lldrawpoolterrain.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/indra/newview/lldrawpoolterrain.cpp b/indra/newview/lldrawpoolterrain.cpp index e716214d72..ba2b00ee4e 100644 --- a/indra/newview/lldrawpoolterrain.cpp +++ b/indra/newview/lldrawpoolterrain.cpp @@ -48,6 +48,7 @@ #include "pipeline.h" #include "llviewershadermgr.h" #include "llrender.h" +#include "llenvironment.h" const F32 DETAIL_SCALE = 1.f/16.f; int DebugDetailMap = 0; @@ -259,6 +260,9 @@ void LLDrawPoolTerrain::beginShadowPass(S32 pass) LLFacePool::beginRenderPass(pass); gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE); gDeferredShadowProgram.bind(); + + LLEnvironment& environment = LLEnvironment::instance(); + gDeferredShadowProgram.uniform1i(LLShaderMgr::SUN_UP_FACTOR, environment.getIsSunUp() ? 1 : 0); } void LLDrawPoolTerrain::endShadowPass(S32 pass) |