月球大数据地理空间分析展示平台-【前端】-月球2期前端
surprise
2023-11-27 f5763f787d5cc5aa0b7d248e0f494c4232f1e3f3
src/assets/js/Map/index.js
@@ -29,32 +29,37 @@
      StaticFileBaseUrl: config.StaticFileBaseUrl,
      ellipsoidCoordinates: 'MOON2000',
      timeline: true,
      shadowBackCul1: false,
      requestWebgl2: false
      shadowBackCul1: false
    });
    this.earthCtrl.Viewer.scene.debugShowFramesPerSecond = true
    this.earthCtrl.coreMap.scene.screenSpaceCameraController.enableCollisionDetection = true;
    this.earthCtrl.Viewer.scene.globe.terrainExaggeration = 1.00001
    this.earthCtrl.coreMap.scene.globe.enableLighting = true;
    // this.earthCtrl.shadowMap.maximumDistance = 10000.0;
    window.earthCtrl = this.earthCtrl;
    window.Viewer = this.earthCtrl._Viewer;
    Viewer.scene.skyAtmosphere.show = false;
    window.Cesium = SmartEarth.Cesium;
    window.sgworld = earthCtrl;
    sgworld.Creator.SimpleGraphic.edit(true, { editProp: false });
    // ================
    // 设置阴影
     Viewer.scene.globe.lightingFadeOutDistance = 5.8e+7;
    Viewer.scene.globe.enableLighting=false;
    earthCtrl.shadows = false;
    // 最小缩放高度(米)
    // Viewer.scene.screenSpaceCameraController.minimumZoomDistance =10000;
    // 最大缩放高度(米)
    // Viewer.scene.screenSpaceCameraController.maximumZoomDistance = 5000000;
    //=======================
    //阴影分析
    Viewer.scene.globe.lightingFadeOutDistance = 5.8e+7;
    Viewer.scene.globe.enableLighting = false;
    earthCtrl.shadows = false;
    //设置球体颜色
    window.Viewer.scene.globe.baseColor = new Cesium.Color.fromCssColorString('#A9A9A9');
    //清除所有默认图层 
    window.Viewer.imageryLayers.removeAll();
    window.setLayer();
    // Viewer.scene.globe.depthTestAgainstTerrain = true;
    Viewer.scene.globe.depthTestAgainstTerrain = false; // 开启深度测试
    Viewer.animation.container.style.visibility = "hidden";
    Viewer.timeline.container.style.visibility = "hidden";
@@ -201,4 +206,4 @@
    console.log(moonPosition);
  },
};
export default InitMap;
export default InitMap;