diff options
author | Graham Linden <graham@lindenlab.com> | 2018-08-31 16:20:30 +0100 |
---|---|---|
committer | Graham Linden <graham@lindenlab.com> | 2018-08-31 16:20:30 +0100 |
commit | 6f8f307858feaeec30e0be0ae3957022be715e4a (patch) | |
tree | f3550913d5bae8d6dd37ec2fab6ecbf668308e31 /indra | |
parent | d452fd77eff53c031c74301dd44a35edce6da95b (diff) |
MAINT-8983 cut RenderShadowBias down to -0.004 to get shadows reconnected to the ground
Diffstat (limited to 'indra')
-rw-r--r-- | indra/newview/app_settings/settings.xml | 2 | ||||
-rw-r--r-- | indra/newview/pipeline.cpp | 3 |
2 files changed, 3 insertions, 2 deletions
diff --git a/indra/newview/app_settings/settings.xml b/indra/newview/app_settings/settings.xml index d30657a30a..214b1a1965 100644 --- a/indra/newview/app_settings/settings.xml +++ b/indra/newview/app_settings/settings.xml @@ -9055,7 +9055,7 @@ <key>Type</key> <string>F32</string> <key>Value</key> - <real>-0.008</real> + <real>-0.004</real> </map> <key>RenderShadowOffset</key> <map> diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp index c33903dff9..bfb7eb3f6a 100644 --- a/indra/newview/pipeline.cpp +++ b/indra/newview/pipeline.cpp @@ -8378,11 +8378,12 @@ void LLPipeline::bindDeferredShader(LLGLSLShader& shader, U32 light_index, U32 n //F32 shadow_offset_error = 1.f + RenderShadowOffsetError * fabsf(LLViewerCamera::getInstance()->getOrigin().mV[2]); F32 shadow_bias_error = RenderShadowBiasError * fabsf(LLViewerCamera::getInstance()->getOrigin().mV[2])/3000.f; + F32 shadow_bias = RenderShadowBias + shadow_bias_error; shader.uniform2f(LLShaderMgr::DEFERRED_SCREEN_RES, mDeferredScreen.getWidth(), mDeferredScreen.getHeight()); shader.uniform1f(LLShaderMgr::DEFERRED_NEAR_CLIP, LLViewerCamera::getInstance()->getNear()*2.f); shader.uniform1f (LLShaderMgr::DEFERRED_SHADOW_OFFSET, RenderShadowOffset); //*shadow_offset_error); - shader.uniform1f(LLShaderMgr::DEFERRED_SHADOW_BIAS, RenderShadowBias+shadow_bias_error); + shader.uniform1f(LLShaderMgr::DEFERRED_SHADOW_BIAS, shadow_bias); shader.uniform1f(LLShaderMgr::DEFERRED_SPOT_SHADOW_OFFSET, RenderSpotShadowOffset); shader.uniform1f(LLShaderMgr::DEFERRED_SPOT_SHADOW_BIAS, RenderSpotShadowBias); |