Good point Kevin, it might have to do with how Lumen handles materials with opacity masks. And you are correct it’s really not a Cesium “issue” but more of a Unreal 5/Lumen issue.
Here is a test scene I have without Cesium implemented.
The scene without anything covering the right building:
The same scene but mesh over one of the buildings (this is just for reference):
Same scene but with a Opacity Mask Material on the white box set to a value of 0:
And as we can see the same shadow issue appear on the building on the right that is now inside the mesh with a opacity mask on it.
Here is also the same scene with the cube with a opacity mask on but with “Use Hardware Ray Tracing when available” turned off in Render settings:
It’s a bit different but does not solve the issue in this specific example. So even turning this off might not solve the issue in all cases. Changing the Material from Opacity Mask to normal Opacity does fix the issue.
I have tried and got the same issues (both the shadow issue and the geo popping up issue) on both 5.3 and 5.4.
So as a conclusion it seems that Unreal Engine 5 & Lumen does not play well with Opacity Mask materials and will create dark shadows under/inside the mesh that uses the Opacity Mask material.
Solution: The solution I have found for the shadow issues is turning on “two sided” for the material that have the opacity mask on it.
Same scene as before and same material with a value of 0 in the opacity mask constant but with two sided turned on and Use Hardware Ray Tracing when available in Render settings is also turned on:
But it seems this does not apply for the Cesium M_CesiumBaseMaterial, turning on Two-sided does unfortunately not fix the issue, any idea why Kevin? Is there somewhere else I might have to change to two-sided?
Here is a image of what I have done in a test scene with cesium:
Thanks again for the help Kevin!