Skip to content

Commit

Permalink
Fix normal bias getting enabled when a light is VSM even if it should…
Browse files Browse the repository at this point in the history
…n't. (#5417)
  • Loading branch information
GSterbrant authored and slimbuck committed Jun 22, 2023
1 parent 8600c09 commit dc6b671
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/scene/shader-lib/programs/lit-shader.js
Original file line number Diff line number Diff line change
Expand Up @@ -1252,7 +1252,7 @@ class LitShader {
}

if (shadowReadMode !== null) {
if (light._normalOffsetBias) {
if (light._normalOffsetBias && !light._isVsm) {
func.append("#define SHADOW_SAMPLE_NORMAL_OFFSET");
}
if (lightType === LIGHTTYPE_DIRECTIONAL) {
Expand Down

0 comments on commit dc6b671

Please sign in to comment.