The GIS function in Wings Engine integrates the complete functions of CesiumJS, and develops a complete interface of CesiumJS to facilitate the rapid migration of previous CesiumJS projects.
The Wings Engine GIS template can be added in the following two ways
Select the Code tab and click Add code file.
Save the following code as CesiumDemo.js.
1 | class CesiumDemo { |
In the code option just added, click and select CesiumDemo.js to upload.
The main camera in Whale Twin is a bird’s-eye view camera by default. This camera cannot be controlled by CesiumJS code and needs to be changed to a Cesium camera. Double-click the Whale Twin component in the screen (note that it is not double-clicked in the layer panel) to enter the edit mode. Select the scene component and change the main camera in the property panel on the right to a Cesium camera.
After saving the project, close the project and reopen it. We can see that the effect of the first project is already there.