| | |
| | | import ImageTrailMaterial from '/@/utils/cesium/ImageTrailMaterial' |
| | | import { ref } from 'vue' |
| | | import { cesiumOperation } from '/@/hooks/use-cesium-tsa' |
| | | import { template as xmlTemplate } from '/@/utils/cesium/use-kmz-tsa' |
| | | const { addPolyline, getEntityById } = cesiumOperation() |
| | | |
| | | const getResource = (name: string) => { |
| | |
| | | } |
| | | interface tragetPoint { |
| | | position: Cesium.Cartesian3 |
| | | isUseGlobalHeight: boolean, |
| | | isUseGlobalHeight: boolean |
| | | eventList: eventParmas[] |
| | | } |
| | | |
| | |
| | | // kml中的全部实体 |
| | | const kmlEntities = ref<Cesium.Entity[]>([]) |
| | | |
| | | const selectPointIndex = ref<number | null>(null) |
| | | |
| | | const useMapDraw = ( |
| | | dataSource: Cesium.DataSource | any, |
| | | entitiesList: Cesium.Entity[] | any, |
| | |
| | | btmStartPoint = Cesium.Cartesian3.fromDegrees( |
| | | Number(startPointPosition[1]), |
| | | Number(startPointPosition[0]), |
| | | Number(startPointPosition[2]) |
| | | Number(startPointPosition[2]), |
| | | ) |
| | | // 参考起飞点“海拔高度,与“参考起飞点”中的椭球高度对应 |
| | | // const posterHeightRegStr = getKmlParams(kmlRes, true, { |
| | |
| | | verticalOrigin: Cesium.VerticalOrigin.BOTTOM, |
| | | disableDepthTestDistance: Number.POSITIVE_INFINITY, |
| | | pixelOffset: new Cesium.Cartesian2(0, -40), |
| | | show: false |
| | | }) |
| | | // 广告牌隐藏 |
| | | // entity.label._show = false |
| | | // 修改点的信息 |
| | | entity.point = new Cesium.PointGraphics({ |
| | | pixelSize: 20, |
| | |
| | | } |
| | | } |
| | | |
| | | export { waylinePointsEvent, waylineDetails, kmlEntities } |
| | | export { waylinePointsEvent, waylineDetails, kmlEntities, selectPointIndex } |
| | | export default useMapDraw |