On low settings SMRT's Texel Dithering is leaking directional light into interior spaces.

Hi,

On our project we have encountered a problem where on our “Low” quality preset we essentially have the following settings:

r.Shadow.Virtual.SMRT.RayLengthScaleDirectional=0
r.Shadow.Virtual.SMRT.TexelDitherScaleDirectional=5

The idea is that we want to be aggressive with our shadow cost optimisations and set RayLengthScaleDirectional to 0, and then compensate for the harsh shadows by dithering the results through TexelDitherScaleDirectional.

On the whole, this gives us adequate results, except when our sun directional light hits an interior (or otherwise shadowed surface) at a shallow angle. At which point we see the shadows dithering on the internal surface and letting a lot of light come through.

(The light here is not lumen leaking, it is entirely the SMRT dithering a strip of light into existence)

Do you have any recommendations for steps we can take to still keep the shadows cheap for our minspec profile, yet avoid the hard jagged edged shadows that we get in return? The hard jagged edged shadows in themselves would not even be so bad on just the environment, if it wasnt for them to look horrible on our viewarms/ held tools.

Thank you for looking into this!

Steps to Reproduce

  • Load up the provided project package
  • Open SMRT_TexelDitherScale.umap
  • Set Viewport Scalability to high.
  • Observe that the dithered shadow map causes light to leak indoors
  • Set: r.Shadow.Virtual.SMRT.TexelDitherScaleDirectional 5
    • Observe that the behaviour gets worse
  • Set: r.Shadow.Virtual.SMRT.TexelDitherScaleDirectional 5
    • Observe that the behaviour is gone.

Hi Mark,

I would recommend either enabling contact shadows on the light, increasing the geometry thickness, tweaking back the SMRT parameters or/and increasing shadowmap resolution.

Improvements for VSM on low-end is a domain we are actively investigating.