3D Tiles crashes with Cesium 1.97

Hi all,
I have uploaded a 3D Tileset on ION.
This is a 3D Tileset made of CMPT/I3DM tiles representing trees (with 3 LOD).
This Tileset displays fine with Cesium 1.84 but crashes with 1.97.

I get this error:
TypeError: Cannot read properties of undefined (reading ‘configurePipeline’)
at wl.buildDrawCommands (https://cesium.com/downloads/cesiumjs/releases/1.97/Build/Cesium/Cesium.js:4411:5330)
at P8e (https://cesium.com/downloads/cesiumjs/releases/1.97/Build/Cesium/Cesium.js:4411:36339)
at Co.update (https://cesium.com/downloads/cesiumjs/releases/1.97/Build/Cesium/Cesium.js:4411:34420)
at ps.update (https://cesium.com/downloads/cesiumjs/releases/1.97/Build/Cesium/Cesium.js:4411:49130)
at wm.update (https://cesium.com/downloads/cesiumjs/releases/1.97/Build/Cesium/Cesium.js:3165:12811)
at Uo.process (https://cesium.com/downloads/cesiumjs/releases/1.97/Build/Cesium/Cesium.js:5117:70516)
at A7e (https://cesium.com/downloads/cesiumjs/releases/1.97/Build/Cesium/Cesium.js:5117:103378)
at Os.prePassesUpdate (https://cesium.com/downloads/cesiumjs/releases/1.97/Build/Cesium/Cesium.js:5117:101612)
at Bs.prePassesUpdate (https://cesium.com/downloads/cesiumjs/releases/1.97/Build/Cesium/Cesium.js:5288:95687)
at Lft (https://cesium.com/downloads/cesiumjs/releases/1.97/Build/Cesium/Cesium.js:8450:38365)

Note that it displays fine in the preview window of my ion account, but when I click on ‘Open complete code example’ which displays it in the SandCastle, It crashes.

In the same way, in my own cesium-based application, I get no error with Cesium1.84 but I started to get the crash when I tried to update to 1.97.

Anyone here knows If there is a workaround or have an explanation about this crash ?

Thanks in advance,
Frédéric.

Hi @ftrastour,

Cesium 1.97 introduced a new architecture for loading glTF models. This code is also used for Cesium3DTileset.

I haven’t seen this error before when loading cmpt or i3dm tilesets. Could you provide the asset ID so we can look into this further?

Thanks,
Peter

Hi Peter,

The asset ID is :

image001.png

image002.png

image003.png

image004.png

Hi @ftrastour,

Your last message appears to be cut off. Could you send the asset ID again? Thanks!

Hi Peter,

the asset ID on my account (user:ftrastour) is 1320054 (trees_denses_lods_1000_50).

Let me know if you prefer to examine a smaller Tileset.

Thanks,

Fred.

image001.png

image002.png

image003.png

image004.png

Hi @ftrastour,

Thank you for the asset ID, I was able to try out your tileset and reproduce the problem. Your tileset uses a glTF with the MSFT_lod extension. Since CesiumJS does not support this extension, the 2 LOD nodes are treated as unused nodes. However, there was a bug in the new Model code where unused nodes were undefined, and that leads to the crash. Fortunately, it just was a matter of filtering out the undefined nodes in the loop.

I opened Filter unused runtime nodes by ptrgags · Pull Request #10813 · CesiumGS/cesium · GitHub to fix this bug. Here’s a screenshot of it running with your data:

Hi Peter,

thanks a lot for having looked to this issue and fixed it.

On my side I will check how to remove these unused nodes which probably make our 3D models bigger than really needed.

Regards,
Fred.