The offset position of dynamic shadows problem.

I have a questions about dynamick shadows with Stationary light source. My shadows from Movable meshes are jump depending on the position of the camera. Look at the shadows on the cat.
71883-71884-

Gif example

Hey Allien,

It almost seems like an LOD popping issue, as when you get closer the LOD for the mesh casting the shadow switches. If you do not have LODs in place, then we can rule that out as the culprit.

This could also be due to your shadow distances applied within the Cascaded Shadow map options of your light source.

Could you provide me with some screenshots of your main source of light that is casting producing these shadows?

Thank you,

Hello ,

I use point or spot light source. Of course i have no any LOD’s for my static meshes. Also for good shadow quality i use these settings:

r.ShadowQuality=5
r.Shadow.TexelsPerPixel 200
r.Shadow.MaxResolution 4096
r.Shadow.SpotLightDepthBias 0
r.Shadow.RadiusThreshold 0.03 

In any case the problem can be seen with the default settings but not so clearly. I do not see sense in additional screenshots of my light source, another unreal user’s easily reproduce bug with dafault point or spot lights while try to help me. Add some other examples:
72139-
[GIF][2]

Where can i change Cascaded Shadow map options for spot/point lights? I saw some of them only in Directional light source.

Sincerely,

Alexander Goryachev.

I should have been a bit more clear. I was requesting the properties of your light actor, i.e. Light Type (Directional, Point, or Spot), Mobility (Static, Stationary, Movable), and other settings.

Cascaded Shadow Maps are currently only available for Directional Lights which is why I mentioned this option.

I attempted to reproduce what you are reporting in a blank level using a similar set-up, and am not seeing the shadowing issue on my end. I even entered the the rendering console commands you provided, and still did not see any shadowing issues. I will mention that I made sure my ‘Engine Scalability’ settings were all set to ‘Epic’, and the ‘Lighting Quality’ was set on ‘Production’.

Also, since I was using a BSP to create the walls, I made sure the Lightmap Resolution was set to 4.0 which provides a denser light and shadow map when working on brush surfaces.

Could you provide me with some reproducible steps so I can get this to appear in a blank project?

Thanks,

  1. Create empty scene.

  2. Use meshes from attachment and place all of them in 0,0,0 coordinates.

  3. Chandelier01 and HelMetal01 must be Movable.

  4. Put Stationary LightSpot inside Chandelier01.

  5. Build light.

Attachment

I am not experiencing the shadow popping that you are reporting. I did have to change the default Lightmap Resolution of your wall mesh to 512, and the wall tube to 128, and set the lighting quality to production to see the best results.

Looks like you are bake lightmaps from Chandelier01 and HelMetal01, they must be movable objects and cast dynamic shadows. I just add my simple test project in attachment.

http://puu.sh/mfDrJ/eeff688246.jpg

Attachment from DropBox: [link][2]

So I believe I found the answer to your issue. Since your objects are movable, and your light is Stationary, meaning it can bake lightmaps/shadowmaps and produce dynamic shadows as well, you will want to make sure your objects are enabled to bake the light as if it were static, but still produce the dynamic shadows.

On both your HelMetal01 and your Chandelier01, enable the ‘Light as if Static’ option to be able to bake static shadows for a movable object. If you don’t want to bake lighting for that light source, change its mobility to movable instead of stationary to get the highest quality. A lot of people think that changing a light to movable is going to have a huge performance impact, but that isn’t always the case. It depends on what it is being used for, and how much of the scene the light source is affecting.

Light as if Static

For a more in depth understanding of Stationary Lighting, take a look at our documentation provided in the link below.

Stationary Lights

https://docs.unrealengine.com/latest/INT/Engine/Rendering/LightingAndShadows/LightMobility/StationaryLights/index.html

If you have further questions, please let me know.

Thanks,

Thanks for the answer. But I need a high-quality dynamic shadows is using Staionary light source. Basically, I got what I wanted, there was only a problem with offset shadows. I’ll try to find a solution to the problem itself again.

You can still produce a high quality shadow using the sationary light by tweaking some settings. Try increasing the resolution of the walls receiving the shadows. Something like 256 up from 64 will definitely help. Also making sure you settings are all on Epic and your Lighting Quality is set to Production. You can also reduce the shadow bias and increase the shadow sharpness. There are a lot of ways to increase shadow quality without losing performance, it’s is all about finding the appropriate balance for your project/scene.

Thanks,

I have repeatedly tried everything that you advised. This is a problem of another kind is not related to quality.

If you manage to find the culprit of the changing shadows, let me know. I will also mention, you are using the ‘Generate Mesh Distance Fields’ option within your Project Settings.

Perhaps try increase the ‘Distance Field Resolution Scale’ of your meshes casting shadows.

That’s all I also tried. If there are more ideas do not forget to throw it to me!

Are you using the ‘Mesh Distance Field’ visualizer when making the changes to your Distance Field Resolution Scale of your Static Mesh actors?

This is found via the Show>Visualize>Mesh Distance Fields

Yep!
But the problem remains, in any case. I’m beginning to think that is a bug.

I was able to reproduce the issue on my end with the help of a team member and we are currently investigating whether or not this is a bug, or just a variable that needs to be changed for the light actor itself to resolve the issue.

If we are unable to resolve the issue, we will continue with the bug reporting process. Thanks for your patience while we investigate.