| | |
| | | * @Author: shuishen 1109946754@qq.com |
| | | * @Date: 2024-10-25 15:09:55 |
| | | * @LastEditors: shuishen 1109946754@qq.com |
| | | * @LastEditTime: 2024-11-04 18:08:12 |
| | | * @LastEditTime: 2024-11-07 16:15:48 |
| | | * @FilePath: \bigScreen\src\hooks\initMap.js |
| | | * @Description: |
| | | * |
| | |
| | | |
| | | export function readyViewer () { |
| | | const Cesium = DC.getLib('Cesium') |
| | | const { appContext } = getCurrentInstance() |
| | | const store = useMap() |
| | | |
| | | function initMap () { |
| | |
| | | |
| | | viewer = new DC.Viewer('viewer-container') |
| | | |
| | | const global = appContext.config.globalProperties |
| | | global.$viewer = viewer |
| | | window.$viewer = viewer |
| | | |
| | | global.$viewer.zoomToPosition(new DC.Position( |
| | | window.$viewer.zoomToPosition(new DC.Position( |
| | | 115.1048036679409, |
| | | 27.276835758787513, |
| | | 4000, |
| | |
| | | -90, |
| | | 0 |
| | | ), () => { |
| | | |
| | | |
| | | store.setLoadMap(true) |
| | | }) |
| | | }) |