From 37f92c1698cd0cef1aa3d8a21a13cd99510e86e9 Mon Sep 17 00:00:00 2001 From: Dave Parks Date: Thu, 5 Dec 2024 13:10:13 -0800 Subject: Fix for legacy skies with bright suns not matching FS 6.6.17 (#3214) --- indra/llrender/llrender.cpp | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'indra/llrender/llrender.cpp') diff --git a/indra/llrender/llrender.cpp b/indra/llrender/llrender.cpp index eb2cd560a6..1d53850f74 100644 --- a/indra/llrender/llrender.cpp +++ b/indra/llrender/llrender.cpp @@ -70,6 +70,7 @@ U32 LLTexUnit::sWhiteTexture = 0; bool LLRender::sGLCoreProfile = false; bool LLRender::sNsightDebugSupport = false; LLVector2 LLRender::sUIGLScaleFactor = LLVector2(1.f, 1.f); +bool LLRender::sClassicMode = false; struct LLVBCache { @@ -972,9 +973,13 @@ void LLRender::syncLightState() shader->uniform3fv(LLShaderMgr::LIGHT_DIFFUSE, LL_NUM_LIGHT_UNITS, diffuse[0].mV); shader->uniform3fv(LLShaderMgr::LIGHT_AMBIENT, 1, mAmbientLightColor.mV); shader->uniform1i(LLShaderMgr::SUN_UP_FACTOR, sun_primary[0] ? 1 : 0); - //shader->uniform3fv(LLShaderMgr::AMBIENT, 1, mAmbientLightColor.mV); - //shader->uniform3fv(LLShaderMgr::SUNLIGHT_COLOR, 1, diffuse[0].mV); - //shader->uniform3fv(LLShaderMgr::MOONLIGHT_COLOR, 1, diffuse_b[0].mV); + + if (sClassicMode) + { + shader->uniform3fv(LLShaderMgr::AMBIENT, 1, mAmbientLightColor.mV); + shader->uniform3fv(LLShaderMgr::SUNLIGHT_COLOR, 1, diffuse[0].mV); + shader->uniform3fv(LLShaderMgr::MOONLIGHT_COLOR, 1, diffuse_b[0].mV); + } } } -- cgit v1.2.3