From 535c16b409fbfa2d25b34104ba93d54a5cb91fa6 Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Wed, 22 Mar 2023 16:19:11 +0800
Subject: [PATCH] 活动流动墙

---
 src/components/map/index.vue |   24 +++++++++++++++++++++++-
 1 files changed, 23 insertions(+), 1 deletions(-)

diff --git a/src/components/map/index.vue b/src/components/map/index.vue
index 77409e0..55250b5 100644
--- a/src/components/map/index.vue
+++ b/src/components/map/index.vue
@@ -2,7 +2,7 @@
  * @Author: shuishen 1109946754@qq.com
  * @Date: 2022-08-18 17:00:30
  * @LastEditors: shuishen 1109946754@qq.com
- * @LastEditTime: 2023-03-21 09:53:10
+ * @LastEditTime: 2023-03-22 16:17:41
  * @FilePath: \srs-police-affairs\src\components\map\index.vue
  * @Description: 公用地图组件
  * 
@@ -480,6 +480,10 @@
             that.layerPolylineAdd(params.layerName, params.positions, params.material, params.width, params.params, params.incident)
         })
 
+        this.$EventBus.$on('layerWallAdd', (params) => {
+            that.layerWallAdd(params.layerName, params.positions, params.imgUrl)
+        })
+
         this.$EventBus.$on('getOverLayerID', (params) => {
             that.getOverLayerID(params.layerName, params.ids, params.cb)
         })
@@ -916,6 +920,24 @@
             layersObjcect[layerName].addOverlay(polyline)
         },
 
+
+        layerWallAdd (layerName, positions, imgUrl) {
+            if (!layersObjcect[layerName] || layersObjcect[layerName] == null) {
+                this.mapAddLayer(layerName, 'VectorLayer')
+            }
+
+            let wall = new global.DC.Wall(positions)
+            wall.setStyle({
+                material: new global.DC.WallImageTrailMaterialProperty({
+                    image: imgUrl,
+                    color: global.DC.Namespace.Cesium.Color.fromBytes(255, 226, 97, 200),
+                    repeat: { x: 3, y: 1 },
+                    speed: 4
+                })
+            })
+            layersObjcect[layerName].addOverlay(wall)
+        },
+
         /**
          * @description: 通过ID获取图层
          * @return {*}

--
Gitblit v1.9.3