About 3dtiles render

I created a tool to convert a 3D Tiles file myself, but after rendering it in the latest version of Cesium, some triangular faces appear black. At first, I thought the normals were inverted, but upon checking, the normals are correct. In the test data I uploaded, Folder 2 contains Tile_L0_0_1_0.glb, Tile_L1_0_1_0.glb, and Tile_L2_0_1_0.glb. These three files represent the same model but with different levels of simplification. The normal directions of these three files are consistent, yet Tile_L0_0_1_0.glb still renders black. I also validated the data using glTF-validator and 3D-Tiles-validator, but no errors were found. Please help me with this issue.

data.zip (12.3 MB)

There are two things coming together here. First, you can see a sudden change when zooming in and out at the right point:

Cesium Forum 43042 dark faces

This inconsistency (two doors being dark, one remaining bright) is likely caused by the structure of the tileset.json: It uses ADD refinement at some places. So it is likely rendering two objects at the exact same place.

But more importantly: The normals appear to be wrong. Looking at the individual GLBs in BabylonJS, with the “render vertex normals” debug toggle shows the normals: For the first one, they point towards the viewer. For the second one, they point up. For the third one, they are pointing in different directions, apparently.

Cesium Forum 43042 dark faces normals wrong