Light shadow Bug?

Hi All,

We encountered a peculiar issue when working with a dynamically generated mesh and want to check if this is a proper bug and not something due to our mistake.
The sample project is here: https://playcanvas.com/editor/project/916295

Clicking the button “Switch Lightsources” disables one light and enables the other one. The only difference between the two is that one uses a Shadow Map setting of Shadow Map PCF 3x3 and the other one uses Shadow Map PCF 5x5.

When PCF 3x3 is used, (and on Windows 11 + Firefox or Android + Firefox) the mesh is rendered black + alpha, but when PCF 5x5 is used, the mesh is rendered properly.


However, the setup works fine on iPad Air + Safari, always proper rendering.
Has anyone encountered this before?
And, is there any real impact of switching between the two PCF types?
Our obvious work-around was to disable “Cast Shadows”, but would like to be sure there isn’t a deeper issue affecting our code.

Thanks!

Hi @sciseedlets,

Was this issue fixed?

Testing on both Chrome and Firefox (Windows 11), I don’t see the issue. Switching lightsources for a couple of times and the model is always correctly rendered.

Hi @Leonidas ,

No, not fixed. It seems that the 3x3 lightsource’s “Cast shadow” was turned off in the test project.
If you try now, it is still not working as described in the bug.

Thanks.

Ah I see, yes I can reproduce. That seems like a bug, try posting an issue about it together with this sample project in the engine repo:

1 Like

Logged as : "Cast Shadow" with PCF3x3 fails to render dynamically generated mesh correctly · Issue #4211 · playcanvas/engine · GitHub

Thanks.

1 Like