Prechádzať zdrojové kódy

在二三维分析模块添加压平入口,将地表透明度改为滑块控制

lkk 1 rok pred
rodič
commit
06d84387bd

+ 54 - 0
src/components/3DAnalysis/Smashing/Smashing.vue

@@ -0,0 +1,54 @@
+<template>
+  <div v-show="smashingComb">
+    <div class="sm-function-module-content">
+      <!-- <div class="sm-point media-hidden"></div>
+      <label class="sm-function-module-sub-section-setting media-hidden">{{
+        Resource.ObserverInformation
+      }}</label> -->
+
+      <div class="boxchild">
+        <el-button type="primary" size="mini" @click="analysis"
+          >倾斜压平</el-button
+        >
+        <el-button type="primary" size="mini" @click="clear">{{
+          Resource.clear
+        }}</el-button>
+      </div>
+    </div>
+  </div>
+</template>
+  
+  <script>
+//   var skyline;
+//   let myChart, s3mInstance;
+
+export default {
+  name: "Sm3dSmashing",
+  props: {
+    //   spatialAnalysisUrl: {
+    //     type: String,
+    //   },
+  },
+  data() {
+    return {
+      sharedState: store.state,
+    };
+  },
+  computed: {
+    smashingComb: function () {
+      return this.sharedState.analysis[5];
+    },
+    analysisShow: function () {
+      return this.sharedState.toolBar[6];
+    },
+  },
+  beforeDestroy() {},
+  mounted() {},
+  methods: {},
+  watch: {},
+};
+</script>
+  
+  <style lang="scss" scoped>
+</style>
+  

+ 2 - 0
src/components/3DAnalysis/Smashing/index.js

@@ -0,0 +1,2 @@
+import Smashing from './Smashing.vue';
+export default Smashing;

+ 14 - 5
src/components/Combinations/analysisCombination/analysisCombination.vue

@@ -7,6 +7,7 @@
         <span :class="{titleColor:shadowqueryShow}" class="title-txt" @click="choose(2)">{{Resource.shadowAnalysis}}</span>
         <span :class="{titleColor:profileShow}" class="title-txt" @click="choose(3)">{{Resource.profile}}</span>
         <span :class="{titleColor:skylineShow}" class="title-txt" @click="choose(4)">{{Resource.skyline}}</span>
+        <span :class="{titleColor:smashingShow}" class="title-txt" @click="choose(5)">{{Resource.smashing}}</span>
         <span class="closeBtn" @click="toggleVisibility">&times;</span>
       </div>
       <!-- 调用子组件 -->
@@ -15,6 +16,7 @@
       <sm3d-shadowquery></sm3d-shadowquery>
       <sm3d-profile></sm3d-profile>
       <sm3d-skyline></sm3d-skyline>
+      <sm3d-smashing></sm3d-smashing>
     </div>
   </div>
 </template>
@@ -27,7 +29,7 @@ export default {
     return {
       sharedState: store.state,
       spatialAnalysisUrl:
-       'http://www.supermapol.com/realspace/services/spatialAnalysis-data_all/restjsr/spatialanalyst/geometry/3d/viewshedbody.json'
+       'http://www.supermapol.com/realspace/services/spatialAnalysis-data_all/restjsr/spatialanalyst/geometry/3d/viewshedbody.json',
     };
   },
 
@@ -47,9 +49,13 @@ export default {
     skylineShow: function () {
       return this.sharedState.analysis[4];
     },
+    smashingShow: function () {
+      return this.sharedState.analysis[5];
+    },
     analysisShow: function () {
       return this.sharedState.toolBar[6];
     },
+
   },
 
   methods: {
@@ -70,16 +76,19 @@ export default {
           store.setAnalysisAction([1, 0, 0, 0, 0]);
           break;
         case 1:
-          store.setAnalysisAction([0, 1, 0, 0, 0]);
+          store.setAnalysisAction([0, 1, 0, 0, 0, 0]);
           break;
         case 2:
-          store.setAnalysisAction([0, 0, 1, 0, 0]);
+          store.setAnalysisAction([0, 0, 1, 0, 0, 0]);
           break;
         case 3:
-          store.setAnalysisAction([0, 0, 0, 1, 0]);
+          store.setAnalysisAction([0, 0, 0, 1, 0, 0]);
+          break;
+          case 5:
+          store.setAnalysisAction([0, 0, 0, 0, 0, 1]);
           break;
         default:
-          store.setAnalysisAction([0, 0, 0, 0, 1]);
+          store.setAnalysisAction([0, 0, 0, 0, 1, 0 ]);
       }
     },
   },

+ 2 - 0
src/components/index.js

@@ -14,6 +14,7 @@ import ShadowQuery from "./3DAnalysis/ShadowQuery/index.js";
 import SightLine from "./3DAnalysis/SightLine/index.js";
 import SkyLine from "./3DAnalysis/SkyLine/index.js";
 import ViewShed from "./3DAnalysis/ViewShed/index.js";
+import Smashing from "./3DAnalysis/Smashing/index.js";
 
 //查询
 import clickQuery from "./Query/clickQuery/index.js";
@@ -105,6 +106,7 @@ const components = [
     SightLine,
     SkyLine,
     ViewShed,
+    Smashing,//倾斜压平
     //场景
     basicOptions,
     sceneCamera,

+ 32 - 11
src/components/sceneAtttribute/camera/camera.vue

@@ -103,14 +103,35 @@
             <label class="label-container">{{
               Resource.SurfaceTransparency
             }}</label>
-            <input
+            <!-- <input
               class="sm-input-long"
               min="0"
               max="1.0"
               step="0.01"
               type="number"
               v-model="SurfaceTransparency"
-            />
+            /> -->
+            <!-- 地表透明度 -->
+            <div class="sm-solider-input-box">
+              <input
+                class="min-solider"
+                min="0"
+                max="1"
+                step="0.01"
+                style="width: 63%"
+                type="range"
+                v-model="SurfaceTransparency"
+              />
+              <input
+                class="min-solider"
+                min="0"
+                max="1"
+                step="0.01"
+                style="width: 24%"
+                type="number"
+                v-model="SurfaceTransparency"
+              />
+            </div>
           </div>
         </div>
       </TabPane>
@@ -224,17 +245,17 @@
         </div>
         <!-- <rotate></rotate> -->
         <div class="row-item">
-        <span>绕点旋转</span>
-        <!-- <div style="width: 12.96rem">
+          <span>绕点旋转</span>
+          <!-- <div style="width: 12.96rem">
           <n-switch v-model="state.rotateShow" size="small" />
         </div> -->
-        <el-switch
-          v-model="state.rotateShow"
-          active-color="#13ce66"
-          inactive-color="#ff4949"
-        >
-        </el-switch>
-      </div>
+          <el-switch
+            v-model="state.rotateShow"
+            active-color="#13ce66"
+            inactive-color="#ff4949"
+          >
+          </el-switch>
+        </div>
         <div v-show="state.rotateShow">
           <div class="flexbox">
             <el-button type="primary" size="mini" @click="onSpinClk">{{

+ 1 - 1
src/store/store.js

@@ -11,7 +11,7 @@ var store2 = {
         sceneAtttribute: [1, 0, 0, 0, 0],
         terrain: [1, 0, 0, 0],
         clip: [1, 0, 0, 0],
-        analysis: [1, 0, 0, 0, 0],
+        analysis: [1, 0, 0, 0, 0, 0],
         cityPlan: [1, 0, 0, 0, 0],
         onlineEdit: [1, 0, 0],
         specialEffects: [0, 0, 0], //特效