Hi,
For our application we are trying to get good looking DAE/GLTF ship models that perform good in Cesium (the model we used with google earth are too complex). We had someone create a Collada ship model for us with -hopefully- a minimal complexity (most likely he used autodesk with collada export).
When using the online glTF converter, I do get a .gltf file but displaying the results fails. Same result for the offline converter. On my system I get the following message for the model:
An error occurred while rendering. Rendering has stopped.
undefined
TypeError: Cannot read property ‘nodes’ of undefined
TypeError: Cannot read property ‘nodes’ of undefined
at computeBoundingSphere (http://localhost:8077/Cesium/Build/CesiumUnminified/Cesium.js:93067:48)
at Model.update (http://localhost:8077/Cesium/Build/CesiumUnminified/Cesium.js:94813:36)
at PrimitiveCollection.update (http://localhost:8077/Cesium/Build/CesiumUnminified/Cesium.js:134977:27)
at updatePrimitives (http://localhost:8077/Cesium/Build/CesiumUnminified/Cesium.js:140351:27)
at render (http://localhost:8077/Cesium/Build/CesiumUnminified/Cesium.js:140404:9)
at Scene.render (http://localhost:8077/Cesium/Build/CesiumUnminified/Cesium.js:140445:13)
at CesiumWidget.render (http://localhost:8077/Cesium/Build/CesiumUnminified/Cesium.js:149817:25)
at render (http://localhost:8077/Cesium/Build/CesiumUnminified/Cesium.js:149237:32)
The code in computeBoundingSphere() is:
var rootNodes = gltf.scenes[gltf.scene].nodes;
Looking into the .gltf file, I can see that gltf.scene and gltf.scenes are both not present. So it is clear why the code crashes.
In the Collada file, I do see scene data:
<library_visual_scenes>
<visual_scene id=“RootNode” name=“RootNode”>
…
and
<instance_visual_scene url=“#RootNode”/>
Any idea what is going wrong here?
The collada file can be viewed without problems in Visual Studio 2013.
(I can’t share the model on the forum, but I could send the .dea and .gltf files via email.)
Thanks, Willem