Shadow from the cable and the roof is like a saw

I created a scene with two light sources using JME3.
When I watch the shadows from the light sources I see that they are unregular and corrugated.
See the video from the link to see this in dynamic.
I also append a screenshot.
What is that for a rendering artefact and how can I change it?

Video

1 Like

That is probably because the shadow map size is much too small for the size of the scene. In my experience, DirectionalLight shadows tend to require higher resolution shadow maps than PointLight or SpotLight shadows do in order to look ok.

2 Likes

In addition to the shadow map size, there are other parameters you can mess with. It would be helpful to know anything about your scene and the code you use to setup the shadow filter.

2 Likes

@codex Yes, you was right. I have increased my shadow map size up to 16384 and got a better result. Thanks!

1 Like

That is a fairy HUGE shadow map size.

There are other things you can do to get better results with a smaller shadow map size.

1 Like

Such as:

Personally, I prefer EdgeFilteringMode.PCFPOISSON .

2 Likes

Also controlling what part of the scene actually has shadows applied, where it splits between near, and far, etc…

Easier to provide guidance if we know more about the scene, though.

1 Like