Skip to content
Permalink
Browse files
Fix shadow mapping when PCF is disabled (#11888)
  • Loading branch information
x2048 committed Jan 2, 2022
1 parent e030d9c commit 835524654ed95afd1c5584c398a78ac226d0f27e
Showing with 1 addition and 0 deletions.
  1. +1 −0 client/shaders/nodes_shader/opengl_fragment.glsl
@@ -185,6 +185,7 @@ float getPenumbraRadius(sampler2D shadowsampler, vec2 smTexCoord, float realDist
float baseLength = getBaseLength(smTexCoord);
float perspectiveFactor;

if (PCFBOUND == 0.0) return 0.0;
// Return fast if sharp shadows are requested
if (SOFTSHADOWRADIUS <= 1.0) {
perspectiveFactor = getDeltaPerspectiveFactor(baseLength);

0 comments on commit 8355246

Please sign in to comment.