You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Click Play-in-Editor, and the tileset will render, but it will be missing its raster overlays (among other things).
The reason is that the new material doesn't have UCesiumMaterialUserData attached to it, so it doesn't know the mapping between material layer name (such as Overlay0) and the material layer index used to set material parameters. Adding UCesiumMaterialUserData is not an option, because the API necessary to find the layer names is only available in the Editor.
Reported here:
https://community.cesium.com/t/cesium-for-unreal-3dtiles-dynamicmaterial/37034
To reproduce, create a Level Blueprint like this:
https://blueprintue.com/blueprint/oyczy--l/
Click Play-in-Editor, and the tileset will render, but it will be missing its raster overlays (among other things).
The reason is that the new material doesn't have
UCesiumMaterialUserData
attached to it, so it doesn't know the mapping between material layer name (such asOverlay0
) and the material layer index used to set material parameters. AddingUCesiumMaterialUserData
is not an option, because the API necessary to find the layer names is only available in the Editor.The best solution, I think, is to modify the code starting here:
https://github.com/CesiumGS/cesium-unreal/blob/v2.11.0/Source/CesiumRuntime/Private/CesiumGltfComponent.cpp#L3024
So that, rather than just checking the
pBaseAsMaterialInstance
forUCesiumMaterialUserData
, it also walks theParent
chain looking for a parent material that has it.The text was updated successfully, but these errors were encountered: