From a51d0169ce227ca498bafa38eb9519267b308b91 Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Sat, 31 Jan 2026 17:18:24 +0800
Subject: [PATCH] feat:无人机轨迹动画调整
---
applications/drone-command/src/components/map-container/device-map-container.vue | 11 +++++++++--
1 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/applications/drone-command/src/components/map-container/device-map-container.vue b/applications/drone-command/src/components/map-container/device-map-container.vue
index e1f0a12..650d950 100644
--- a/applications/drone-command/src/components/map-container/device-map-container.vue
+++ b/applications/drone-command/src/components/map-container/device-map-container.vue
@@ -77,7 +77,7 @@
const CLUSTER_HEIGHT = 100000
const DETAIL_HEIGHT = 10000
const POLYGON_HEIGHT_M = 0.2
-const DRONE_TRACK_DURATION_S = 10 * 60
+const DRONE_TRACK_DURATION_S = 30 * 60
const props = defineProps({
allDevices: {
@@ -228,13 +228,20 @@
offset: Math.random() * PULSE_DURATION_S,
entity: null,
}
+ const getPulseHeight = () => {
+ const pos = getBillboardPosition(billboard)
+ if (!pos) return 0
+ const carto = Cesium.Cartographic.fromCartesian(pos)
+ return carto?.height ?? 0
+ }
pulse.entity = viewer.entities.add({
position: new Cesium.CallbackProperty(() => getBillboardPosition(billboard), false),
ellipse: {
semiMajorAxis: new Cesium.CallbackProperty(() => getPulseRadius(pulse), false),
semiMinorAxis: new Cesium.CallbackProperty(() => getPulseRadius(pulse), false),
material,
- heightReference: Cesium.HeightReference.CLAMP_TO_GROUND,
+ height: new Cesium.CallbackProperty(() => getPulseHeight(), false),
+ heightReference: Cesium.HeightReference.NONE,
},
})
favoritePulseEntities.push(pulse)
--
Gitblit v1.9.3