| | |
| | | import * as Cesium from 'cesium' |
| | | import useKmzTsa, { template as xmlTemplate } from '/@/utils/cesium/use-kmz-tsa' |
| | | import useMapDraw, { kmlEntities as globalEntities } from '/@/utils/cesium/use-map-draw' |
| | | import { useMyStore } from '/@/store' |
| | | const store = useMyStore() |
| | | const { appContext }: any = getCurrentInstance() |
| | | const global = appContext.config.globalProperties |
| | | const kmzUtils = useKmzTsa() |
| | |
| | | const height = 6 |
| | | const takeOffPoint = [latitude, longitude, height] |
| | | xmlTemplate.value.missionConfig.takeOffRefPoint['#text'] = takeOffPoint.join(',') |
| | | store.commit('SET_WAYLINE_INFO', { |
| | | isShow: true, |
| | | }) |
| | | const xmlStr = kmzUtils.generateXML(xmlTemplate.value) |
| | | mapDraw.drawWayline(globalEntities.value, xmlStr) |
| | | } |