Shadow breaks in hard edges [Lightmap]

Hi all. I have weird problem which can’t fix and do not understand why is this happening? Problem is, baked shadow flow (Do not know how to say properly in english) breaks in hard edge.

This is size of mesh for better understanding Lightmap resolution.

Lightmap res. is 512 which I think is high for this mesh. But even with 1024 lightmap this issue still visible.

This is issue I get.

Green line show how the shadows breaks in edges. There is no any gap between those edges and all connected properly.

1.Some edges are not snapped griid but I tried with snapping too and get same result.
2.I connected that edges in lightmap for smooth transition (which I think is not right decision because light illuminate them from different angle) and shadows still breaks same way.

And this is Lightmap with 64x64 greed in UVlayout.

Green pieces are same area where I see problems. As you see there is enough padding (min 2 and max 5) with 64x64 map. And I increased this to 512x512 in my picture so I think this is not problem of that.

My Lightmass setting under world setting tab:

Hello Tural,

There are a few things you can do to increase the resolution of your Shadows. You explained that you have set up your Light Maps properly and increased the resolution within UE4. I have a few questions for you that should help you with your issue.

1.) If you set your lights to stationary or movable does this issue still happen?
2.) If you are using Cascaded Shadow Maps what is your Dynamic Shadow Distance StationaryLight and Num of Dynamic Shadow Cascades set to?
3.) Have you set your Lighting quality to build at production?

After I have this information I should be able to narrow down what is causing this and work towards a solution.

Hello and THX for reply.

  1. When I set directional light to dynamic the issue is not happening. Same as with stationar light without bake.Here is picture.

As you can see shadows is straight lined perfectly in hard edge. I baked light in 4.8 build but still get same weird shadow.
2. I didn’t changed anything in dynamic lighting setting. I didn’t use dynamic light for this scene. All are default setting.
3. Yes. Quality is production.

Oh , when you yesterday wrote me that was 2 oclock evening in my country so I understood your 2nd question wrong. I checked it again today with fresh brain and Dynamic Shadow Distance StationaryLight solved my problem. THX :slight_smile:

So what I understand there is no way to make baked shadow look more accurate with just default setting not matter how is my lightmap uv and res set up. Or is there something still I missed?

You are correct in your assumption that there are limits to the accuracy of your baked shadows. I will link you to a troubleshooting guide for lighting and documentation on lighting and shadows for any further questions you may have.

THX you again. )))

1 Like