CesiumGS / cesium-unreal

Bringing the 3D geospatial ecosystem to Unreal Engine
https://cesium.com/platform/cesium-for-unreal/
Apache License 2.0
902 stars 287 forks source link

Visual noise in Cesium3DTiles (Material) #1359

Closed ftrx closed 3 months ago

ftrx commented 6 months ago

I've noticed today that there is a visual noise on the Cesium3DTiles (its very hard to see, kind of white noise/ pixel artifacts):

https://github.com/CesiumGS/cesium-unreal/assets/1744939/8fe1da6b-05bf-40d4-9dfa-b53facb4df43

it is even more visible when the mesh/3dTiles is selected (so its something in the mesh?):

https://github.com/CesiumGS/cesium-unreal/assets/1744939/051c5b6c-1125-442e-a564-56c7368d2627

Its quite subtle visual noise and far better visible when the 3dTileset is selected. It's mostly noticeable in darker areas and is in VR quite noticeable (also in builds)

It seems like its a Material issue (?) with the standard masked material:

If I change the 3dTileset material to the M_DEPRECATED_CesiumDefaultMasked the issue is gone. Also if disconnect/replace the Alpha Channel of the Vertex Color node from the Opacity/ OpacityMask in the CesiumGlTFFunction MaterialFunction, the issue/noise is gone (so it seems vertex color related?)

If I have time, I'll try to dive into it a bit, but maybe you guys already know the issue/culprit

My Specs

Steps to reproduce:

  1. Open Cesium for Unreal Examples Project
  2. Open any map (for example 04_MAIN_CesiumSublevels)
  3. Go to a darker area (dark textured building or so)
csciguy8 commented 6 months ago

I see it too. Even turning off antialiasing (Project Settings->Anti-Aliasing Method = None), the problem persists.

This does stop the noise from animating at least.

ftrx commented 6 months ago

Some more information from our side: It seems to have something to do with the Material Layers, as the CesiumGltFFunction is also used in the old deprecated material directly and there it works without issue.

Also if I use a new Material Instance of the M_CesiumBaseMaterial with the same parameters as the MI_CesiumThreeOverlaysAndClipping Material Instance the issue seems to be gone...

So maybe a bad asset/ old parameters? but i cannot exclude yet if its cache/DDC related from our side.