From 405df5bd528ad59bcebd14f8fb9505acf9bb41ec Mon Sep 17 00:00:00 2001
From: TreeWish <1131093754@qq.com>
Date: 星期一, 20 二月 2023 18:11:12 +0800
Subject: [PATCH] 工程较多时添加列表滚动和搜索框

---
 src/components/Screen/mapsdk.vue |   69 +++++-----------------------------
 1 files changed, 10 insertions(+), 59 deletions(-)

diff --git a/src/components/Screen/mapsdk.vue b/src/components/Screen/mapsdk.vue
index 18c9190..553eb8b 100644
--- a/src/components/Screen/mapsdk.vue
+++ b/src/components/Screen/mapsdk.vue
@@ -17,38 +17,19 @@
   methods: {
     init3DMap() {
       //鍦板浘鍒濆鍖�
-      window.sgworld = new SmartEarth.SGWorld("Centermapdiv", {
-        licenseServer: window.sceneConfig.licenseServer,
-      })
+      // window.sgworld = new SmartEarth.SGWorld("Centermapdiv", {
+      //   licenseServer: window.sceneConfig.licenseServer,
+      // })
+      window.sgworld = new SmartEarth.SGWorld(
+        "Centermapdiv",
+        SmartEarthRootUrl + "Workers/image/earth.jpg",
+        function () {}
+      )
 
       window.viewer = window.Viewer = window.sgworld._Viewer
-      Viewer.imageryLayers._layers[0].show = false
-      //瀹氫綅
-      // Viewer.camera.flyTo({
-      //   destination: Cesium.Cartesian3.fromDegrees(110, 33, 25000000),
-      // })
-      // Viewer.camera.flyTo({
-      //   destination: {
-      //     x: -10834926.182758586,
-      //     y: 50483318.61217012,
-      //     z: 38375099.7193183,
-      //   },
-      //   orientation: {
-      //     heading: 6.283185307179578,
-      //     roll: 0,
-      //     pitch: -1.56436861046299,
-      //   },
-      // })
-      //寮�鍚� tick61.2
+      // Viewer.imageryLayers._layers[0].show = false
 
-      // Cesium.Camera.DEFAULT_VIEW_RECTANGLE = {
-      //   west: -3.141592653589793,
-      //   south: -1.5707963267948966,
-      //   east: 3.141592653589793,
-      //   north: 1.5707963267948966,
-      // }
-
-      viewer.clock.shouldAnimate = true
+      // viewer.clock.shouldAnimate = true
       //姣忔鏃嬭浆鐨勫姬搴� 瓒婂皬瓒婃參
       var angle = Cesium.Math.toRadians(Math.PI * 1)
       // 鏃嬭浆娆℃暟 鐢ㄦ潵鎺у埗鍋滄
@@ -106,36 +87,6 @@
       }
       // 鍒╃敤鏃堕挓杩涜鐩戝惉
       viewer.clock.onTick.addEventListener(onTickCallback)
-      // setTimeout(() => {
-      //   Viewer.camera.flyTo({
-      //     destination: {
-      //       x: -4022999.313498903,
-      //       y: 19214082.70976515,
-      //       z: 13043510.373621361,
-      //     },
-      //     orientation: {
-      //       heading: 6.283185307179577,
-      //       roll: 0,
-      //       pitch: -1.5643686104630592,
-      //     },
-      //   })
-      // }, 1000)
-
-      // setTimeout(() => {
-      //   Viewer.camera.flyTo({
-      //     destination: {
-      //       x: -3919623.6069864673,
-      //       y: 13752070.475126158,
-      //       z: 8307291.863719194,
-      //     },
-      //     orientation: {
-      //       heading: 6.283185307179582,
-      //       roll: 0,
-      //       pitch: -1.5707039123519846,
-      //     },
-      //   })
-      // }, 1000)
-
       Viewer.imageryLayers.addImageryProvider(
         new Cesium.UrlTemplateImageryProvider({
           url: gaoDeBaseUrl[0].url,

--
Gitblit v1.9.3