Need some help with lighting of the landscape. I set the scene to use dynamic lights, distant field shadows and cascaded shadow maps. The matter is that there will be a day& night cycle but when the sun goes down it causes some light artifacts to be shown as if it lights the scene from below. These artifacts disappear when the sun begins to rise but I would like to get rid of them forever. The problem was a lot worse but I managed to fix it to the current state by correcting some values like distance field shadow distance, dynamic shadow distance [in directional light] and shadow two sided [in the landscape details].
P.S. The landscape actor uses the special tessellation material from advanced material pack.
Put a flat plane under the landscape and scale it up until it’s the same size as the landscape. It will prevent the light coming from below. (I’d prefer to say use a box instead of a flat plane, and adjust width and depth of that until it matches the same size of landscape).
Yes it works, but you have to manage to get the box very close to the edges of the land so that the light cannot go through the gaps. It is possible that I will have to sculpt the edges of landscape to bend down into the box.
There can be a huge distance between the box and the landscape. It’s just meant to block the light it doesn’t require to be blended by landscape edges.
The problem is gone now and it was quite a headache. I tried to correct the intensity of the sun when it was underneath but the blueprint didn’t work. Used this tutorial for that A new, community-hosted Unreal Engine Wiki - Announcements and Releases - Unreal Engine Forums
Although for some reasons I couldn’t connect the light source directly to the “set intensity” node [if you know why please let me know]
The solution of this problem was this - I already had a big bsp cube underneath the landscape, but now I stretched it so that it was wider than the skybox. There was another cube inside the first one with “subtractive” mode so that there was a big deepening inside. But anyway the light kept shining through the land. In the end what I did is just played the scene while being underneath the landscape - on the deepening of the cube. The first time that the light cycled - the whole place was lit and there were funky shadows from the land above, but then it changed and became dark. It seemed so that if the engine wasn’t fully aware of the existence of the cube before that.
Right now I don’t see any issues that were present before and I hope that it will stay that way. Hope this helps you in your work.