Issue : Ray Tracing & Lod Material Shadow casting

Hi everyone !

So this is an issue we are currently facing.
Our setup : Directional light with ray tracing shadowsON, a grass mesh with 2 lods ; Lod0 has a material with cast shadows ON, whereas LOD1 has the same material but no shadow casting. On the left, the meshes had been manually placed / On the right, placed using foliage tool

1st image ↑ : LOD0
2nd image ↓ : LOD1

As we can see, foliage keeps shadowing. Even if we cull the foliage mesh, the shadows remain.
Is this a current limitation ? Is there a workaround for now ?

Thanks !


Hi, same problem here… foliage shadow can’t be culled and LOD cast shadow option is not working.

I am not sure this will be completely helpful to you, but why would you cull shadows with ray tracing? Due to the way ray tracing works, you won’t gain much performance by culling shadows. In fact it is often case that various ray switch fakes actually decrease performance of the ray tracing. The main strong point of ray traced shadows is that even at infinite shadowing distance and very dense geometry, performance stays roughly the same as rays are cast from the camera in screen space, unlike shadow maps that are projected from lights in light space, requiring more resources as geometric density and shadow draw distance increases.

As the geometric complexity and required shadow casting distance increases, the ray traced shadows vs shadowmap performance gap closes up to a certain tipping point after which ray traced shadows are both higher quality as well as **faster **than the shadowmaps. Epic guys were explaining it in some talk, but I can’t remember which.

Technically it is a bug, if it works with manually placed SMs but not with foliage. Regardless though, even if you solved this bug, you would still be left with worse quality results with little to no performance gain :slight_smile:

I agree in general terms but the persistance of LOD0 shadows is a huge issue when you can’t manually place SMs due to the extension of the grass surface…

Thank you very much for your explanations. But this is annoying when the shadows remain while the geometry is culled in the distance.
OP was 4.23, still the same with 4.24.2.

I know this topic is more than a year old, I am now on 4.26 and the issue is still there, did you guys find a solution to this?