1. A concise explanation of the problem you’re experiencing.
If a developer would like to display 3d model (gltf-file) according to Cesium documentation (https://cesiumjs.org/Cesium/Build/Documentation/Entity.html) he has to provide URL to a file with 3d model. See example below. In this case Cesium downloads this model by itself and displays it on a map. Unfortunately, there is no ability to understand when Cesium has downloaded the files and is ready to render it. We need this event, callback or “promise” to start further actions.
2. A minimal code example. If you’ve found a bug, this helps us reproduce and repair it.
3. Context. Why do you need to do this? We might know a better way to accomplish your goal.
There is a number of scenarios in which notifications about loading of models is required.
- We are monitoring the Camera and load models that supposedly appear attached to the visible part of the ground. When the camera moves away, we want to be able to remove the models from the view and, ideally, cancel the loading if it is still in progress. We are talking about hundreds of models, which translates to large number of requests from the browser to server. Better control of the network traffic appears to be critical to us.
4. The Cesium version you’re using, your operating system and browser.
We use the latest Cesium version, which we use within mainly Chrome, Firefox and Safari on Windows, Linux, Android and iOS.