Cascaded shadows too bright

Hello,

I am working on a outdoor scene wherefore I want to implement the cascadedShadowGenerator. In general I am using IBL but I added a directional light to create the shadows. I am fine with placing the light at the same position of the sun in the environment texture but the shadows are way too bright. Increasing the light intensity makes them more visible but first the materials shouldn’t be too eposured and second the shadows don’t become darker with that.

So how am I able make the shadows darker or more intense?

Best

With PBR materials / IBL it is expected to have shadows less strong than with the standard materials. You can try to lower the IBL / light intensity to make the shadows more visible but it’s in general more difficult to have strong shadows than when not using PBR.

That makes sense. But since there is already the parameter penumbraDarkness I assumed it is possible somehow to use a value lower than 0.

Besides that I am very curious how to get rid of the lines on surfaces that are caused by csm. I played around with all available parameters but especially on the ground are the lines clearly visible. Is it possible to get rid of them for the areas on the ground where no object is casting a shadow. Since there is no shadow at all it would be fine if just the light is visible.

I’m not sure what you are speaking about… Maybe a repro in the playground would help.

Maybe it is acne shadow. In this case, it’s the bias parameter you need to tweak.

2 Likes

I created a pg: https://playground.babylonjs.com/#P5Q249#1

You clearly can see this patterns on the surfaces of the sphere the ground. A played around with all parameters but I am not able to get rid of them.

you have to increase the bias. shadowGenerator.bias = 0.01; seems to work in your case

2 Likes

Sorry, I changed the bias parameter in too big steps. Thanks for you help!

1 Like