Shadow artifacts / no shadow is shown

Dear all,

I have some challenges with the shadow:

Why doesn’t the red ball generate any shadow with z=-0.3 (but with z=-0.5)?
Why are the shadow of the yellow one looks that ugly (some artifacts are shown)?

Many thanks for your support/time…!

Best
Andreas

You need to adjust the bias value. Here, 0.00001 works well:

You can also use a filtering method (by default, no filtering is applied) for better shadows (PCF):

See Shadows | Babylon.js Documentation for more info on troubleshooting shadow problems.

2 Likes

Amazing. Many thanks!