Hello, please is there a way to decrease movable light dynamic shadow distance?
I know there is the draw and fade setting in the light… but that makes the whole light go out. I do not need dynamic (or any) shadows at long distances. My game is whole in the underground so i do not need and i do not use directional light/skylight. Is that ok?
I would like to decrease dynamic shadow distance so the shadows disappear sooner… because of performance… It can be set for all light in the whole project for each light separatedly, it does not matter.
Im sure it is very simple but i did not find that setting anywhere and even this question on the forum (most people want the opposite).
You can adjust the shadow distance for individual lights in Unreal Engine. To decrease the movable light dynamic shadow distance, you can use the following steps:
Select the light in the level editor
In the Details panel, under the Light Component section, find the Cast Shadows property
Change the Shadow Distance value to the desired distance. This controls the maximum distance at which dynamic shadows will be cast by the light.
Note that decreasing the shadow distance can improve performance by reducing the number of shadow-casting objects and the amount of shadow data processed by the GPU. However, be careful not to set the shadow distance too low, as this can result in low-quality or inconsistent shadows.
As for your question about the absence of a sky light and directional light, it is fine to not use them in your underground environment as long as you have other sources of light in your scene. You can use other types of lights, such as point lights, spot lights, or area lights, to light your scene.
But this disables the whole light… not only the shadow. So it makes the level very dark in the distance. Im using this now in combination with a light that does not cast shadows at all. So even when it does not draw the shadow casting light, some light stays… but it is darker anyway.
You could turn lights off using Blueprints, you can set it so that when the player enters a specific area or are X amount of distance away from a light the shadow turns off. However, I don’t think that is a great solution.
I think you probably want to look closer at reducing the graphical setting regarding Shadows, rather than manually tweaking or turning them off at a distance. It’s easier to let the game handle it. Have a look at this: Scalability Reference | Unreal Engine 4.27 Documentation
This is a reference from the Scalability Reference:
Thank you. Im learning all about the scaling now… Only thing that works for me is r.Shadow.RadiusThreshold=0.06
But it sets the screen size of the mesh to be/or not to be influenced by shadows. So small meshes shadow pops in when i get closer…
None of those settings is actually based on distance from the light
But i am somewhere where i wanted to be
so thank you very much for the helpful information