| | |
| | | } |
| | | |
| | | .cesium-performanceDisplay-defaultContainer { |
| | | display: none; |
| | | /* top : 32px; |
| | | right: 85px; */ |
| | | /* display: none; */ |
| | | top : 32px; |
| | | right: 85px; |
| | | } |
| | | |
| | | .cesium-viewer-bottom { |
| | |
| | | var shape = this.renderRect(points); |
| | | var step = 0; |
| | | var $this = this; |
| | | |
| | | store.state.isBatchGridArr = true; |
| | | this.handler.setInputAction(function (e) { |
| | | var cartesian = Viewer.scene.pickPosition(e.position); |
| | | if (!Cesium.defined(cartesian)) { |
| | |
| | | } |
| | | |
| | | store.state.batchGridArr = arr; |
| | | |
| | | // 显示点 |
| | | // for (var i = 0; i < arr.length; i++) { |
| | | // var p = arr[i]; |
| | |
| | | var shape = this.renderRect(points); |
| | | var step = 0; |
| | | var $this = this; |
| | | |
| | | store.state.isBatchGridArr =true; |
| | | this.handler.setInputAction(function (e) { |
| | | var cartesian = viewer.scene.pickPosition(e.position); |
| | | if (!Cesium.defined(cartesian)) { |
| | |
| | | this.setInsertGridData(arr, ((i + 1) * (j + 1))); |
| | | } |
| | | } |
| | | store.state.isBatchGridArr =false; |
| | | }, |
| | | async setInsertGridData(res, num) { |
| | | var obj = |
| | |
| | | '桩号_Point', |
| | | ], |
| | | mssageInfo: null, |
| | | propertyNames:null, |
| | | propertyNames: null, |
| | | Init(html) { |
| | | |
| | | if (!html) return; |
| | |
| | | store.state.isshowZhaiHai = false; |
| | | store.state.showMessageInfo = false; |
| | | this.mssageInfo = null; |
| | | store.state.isShowImgUpDate = false; |
| | | store.state.isShowImgUrl= null; |
| | | this.propertyNames=null; |
| | | store.state.isShowImgUpDate = false; |
| | | store.state.isShowImgUrl = null; |
| | | this.propertyNames = null; |
| | | store.state.isireamUrl = null; |
| | | store.state.isShowMenuCount = false; |
| | | |
| | | |
| | | }, |
| | | setTileSetInfo(res) { |
| | | var propertyNames = res.getPropertyIds(); |
| | | if(!propertyNames || propertyNames.length<=0)return; |
| | | this.setRestLayer(); |
| | | var val = []; |
| | | for(var i = 0; i <propertyNames.length;i++){ |
| | | var name= propertyNames[i] |
| | | var obj = { |
| | | name: name, |
| | | value: res.getProperty(name) |
| | | } |
| | | val.push(obj) |
| | | } |
| | | this.showMapInfo(val); |
| | | }, |
| | | setGeoJsonInfo(res) { |
| | | if (res.projectId && res.frameNo) { |
| | | this.setRestLayer(); |
| | | this.setRestLayer(); |
| | | store.state.showZhaiHaiImg = res; |
| | | store.state.isshowZhaiHai = true; |
| | | }else if(res.sourceType && res.sourceType._value == "imgUp"){ |
| | | } else if (res.sourceType && res.sourceType._value == "imgUp") { |
| | | this.setRestLayer(); |
| | | |
| | | |
| | | setTimeout(() => { |
| | | store.state.isShowImgUrl= res._path._value; |
| | | store.state.isShowImgUpDate = true; |
| | | store.state.isShowImgUrl = res._path._value; |
| | | store.state.isShowImgUpDate = true; |
| | | }, 100); |
| | | |
| | | }else { |
| | | |
| | | } else { |
| | | var val_name = res._propertyNames; |
| | | this.propertyNames =res._propertyNames; |
| | | this.propertyNames = res._propertyNames; |
| | | var val = []; |
| | | var enName = ['ZH', 'HY', 'YH', 'HZ', 'Lh', 'R', 'QZ', 'CORNER', 'SL', 'WIDEN'] |
| | | var cnName = [ |
| | | '前缓和曲线起点', |
| | | '圆曲线起点', |
| | | '圆曲线止点', |
| | | '后缓和曲线止点', |
| | | '缓和曲线长度', |
| | | '平曲线半径', |
| | | '圆曲线中心点', |
| | | '转角', |
| | | '超高值', |
| | | '加宽值' |
| | | |
| | | ] |
| | | for (var i = 0; i < val_name.length; i++) { |
| | | var name = val_name[i] |
| | | if (enName.indexOf(name) > -1) { |
| | | name = cnName[enName.indexOf(name)] |
| | | } |
| | | var obj = { |
| | | name: val_name[i], |
| | | name: name, |
| | | value: res[val_name[i]]._value, |
| | | } |
| | | val.push(obj) |
| | | } |
| | | |
| | | |
| | | this.showMapInfo(val); |
| | | } |
| | | }, |
| | |
| | | let lat = Cesium.Math.toDegrees(cartographic.latitude); // 纬度 |
| | | let alt = cartographic.height; // 高度,椭球面height永远等于 |
| | | let coordinate = { |
| | | longitude: Number(lng.toFixed(6)), |
| | | latitude: Number(lat.toFixed(6)), |
| | | longitude: Number(lng), |
| | | latitude: Number(lat), |
| | | altitude: Number(alt.toFixed(2)), |
| | | heading: 0, |
| | | pitch: 0, |
| | | roll: 0, |
| | | scale: 1, |
| | | }; |
| | | |
| | | store.state.coordinate = coordinate; |
| | | if (store.state.addModelFlag) { |
| | | model.setModelCoord(coordinate); |
| | | if(store.state.isBatchGridArr){ |
| | | |
| | | } |
| | | if (store.state.isMeasureFlag) { |
| | | }else if (store.state.addModelFlag) { |
| | | model.setModelCoord(coordinate); |
| | | |
| | | }else if (store.state.isMeasureFlag) { |
| | | store.state.measureCoordObj = coordinate; |
| | | store.state.isShowMeasureCoord = true; |
| | | } |
| | | if (Cesium.defined(nPickFeature)) { |
| | | |
| | | }else if (store.state.isQueryFalag) { |
| | | |
| | | store.state.isQyeryCoord = coordinate; |
| | | |
| | | }else if (Cesium.defined(nPickFeature)) { |
| | | mapInfo.setRestLayer(); |
| | | if (nPickFeature.id && nPickFeature.id.id == 'Rectangle') |
| | | return |
| | |
| | | } else if (name == "DLLMJ0001") { |
| | | store.state.isireamUrl = "/Data/html/hd3dmap.html?id=3493&type=8"; |
| | | store.state.isShowMenuCount = true; |
| | | } else if (name == "DLBZP0023") { |
| | | store.state.isireamUrl = "/Data/html/hd3dmap.html?id=3494&type=5"; |
| | | store.state.isShowMenuCount = true; |
| | | } else if (name == "DLBZP0024") { |
| | | store.state.isireamUrl = "/Data/html/hd3dmap.html?id=3491&type=8"; |
| | | store.state.isShowMenuCount = true; |
| | | }else if(name === "DLBZP0026"){ |
| | | store.state.isireamUrl = "/Data/html/hd3dmap.html?id=3505&type=8"; |
| | | store.state.isShowMenuCount = true; |
| | | }else if(name === "DLBZP0029"){ |
| | | store.state.isireamUrl = "/Data/html/hd3dmap.html?id=3646&type=5"; |
| | | store.state.isShowMenuCount = true; |
| | | }else if(name === "DLBZP0027"){ |
| | | store.state.isireamUrl = "/Data/html/hd3dmap.html?id=3685&type=99"; |
| | | store.state.isShowMenuCount = true; |
| | | } else if(name === "DLBZP0027"){ |
| | | store.state.isireamUrl = "/Data/html/hd3dmap.html?id=3685&type=99"; |
| | | store.state.isShowMenuCount = true; |
| | | }else if(name === "DLBZP0072"){ |
| | | store.state.isireamUrl = "/Data/html/hd3dmap.html?id=3719&type=5"; |
| | | store.state.isShowMenuCount = true; |
| | | }else{ |
| | | mapInfo.setTileSetInfo(nPickFeature) |
| | | } |
| | | |
| | | |
| | | }else{ |
| | | |
| | | } |
| | | } |
| | | if (store.state.isQueryFalag) { |
| | | |
| | | store.state.isQyeryCoord = coordinate; |
| | | } |
| | | |
| | | |
| | | }, Cesium.ScreenSpaceEventType.LEFT_CLICK) |
| | | }, |
| | | addRightClick() { |
| | |
| | | name: this.title.name, |
| | | longitude: res.longitude, |
| | | latitude: res.latitude, |
| | | altitude: res.altitude, |
| | | altitude: 18.1, |
| | | heading: res.heading, |
| | | pitch: res.pitch, |
| | | roll: res.roll, |
| | |
| | | id: res.id, |
| | | url: url, |
| | | scale: res.scale, |
| | | minimumPixelSize: 200, |
| | | maximumScale: 200000, |
| | | minimumPixelSize: 1, |
| | | maximumScale: 10, |
| | | modelMatrix: modelMatrix |
| | | |
| | | })); |
| | |
| | | </div> |
| | | <div class="modelContent"> |
| | | <div v-show="!showMenuGrid" class="contentMessage" v-for="(item, index) in modelOption" :key="index"> |
| | | <div>{{ item.name }}</div> |
| | | <div> |
| | | <label>{{ item.name }}</label> |
| | | |
| | | </div> |
| | | <div>{{ item.value }}</div> |
| | | </div> |
| | | <div v-show="showMenuGrid" class="contentMessage" v-for="(item, index) in modelOption" :key="index"> |
| | |
| | | line-height: 50px; |
| | | border-right: 1px solid white; |
| | | border-top: 1px solid white !important; |
| | | word-wrap:break-word; |
| | | |
| | | } |
| | | |
| | | div:first-child { |
| | |
| | | model.changeLayer(item, true); |
| | | } else { |
| | | model.changeBatchLayer(item, true); |
| | | |
| | | this.$store.state.isBatchGridArr =false; |
| | | let coordinates = this.$store.state.batchGridArr; |
| | | let shape = this.$store.state.batchShape; |
| | | Viewer.entities.remove(shape); |
| | |
| | | window.sgworld = new SmartEarth.EarthCtrl( |
| | | "sdkContainer", |
| | | { |
| | | StaticFileBaseUrl: "../../../static/CimSDK/", |
| | | // StaticFileBaseUrl: "../../../static/CimSDK/", |
| | | // StaticFileBaseUrl: "../../../SW/static/CimSDK/", |
| | | // StaticFileBaseUrl: "../../../JSJKZHGS/static/CimSDK/", |
| | | StaticFileBaseUrl: "../../../JSJKZHGS/static/CimSDK/", |
| | | }, |
| | | {}, |
| | | {}, |
| | |
| | | window.viewer = sgworld._Viewer; |
| | | sgworld._Viewer.scene.moon.show = false; |
| | | // Viewer.terrainProvider=Cesium.createWorldTerrain() |
| | | |
| | | //显示fps |
| | | sgworld._Viewer.scene.debugShowFramesPerSecond = true; |
| | | window.sgwfs = new SmartEarth.WFSTool(sgworld._Viewer, Cesium); |
| | | Viewer.shadows = false; |
| | | //深度检测 |
| | |
| | | ]; |
| | | const router = new Router({ |
| | | mode: "history", |
| | | // base: '/JSJKZHGS',//正式版 打包时解开 |
| | | base: '/JSJKZHGS',//正式版 打包时解开 |
| | | // base: '/SW',//测试版 打包时解开 |
| | | routes, |
| | | }); |
| | |
| | | batchGridArr: [], |
| | | isShowMenuCount:false, |
| | | isireamUrl:null, |
| | | isBatchGridArr:false, |
| | | }, |
| | | mutations: { |
| | | selectedLayer(state, b) { |
| | |
| | | "effectsMaxHeight": 0, |
| | | "skipLevelofDetail": true, |
| | | "preferLeaves": true, |
| | | "maximumScreenSpaceError": 24, |
| | | "maximumScreenSpaceError": 2, |
| | | "maximumMemoryUsage": 1024 |
| | | } |
| | | ], |