소스 검색

提高地球过渡动画的地球亮度

画安 1 일 전
부모
커밋
14e1f6e48c
1개의 변경된 파일18개의 추가작업 그리고 13개의 파일을 삭제
  1. 18 13
      src/components/CesiumTransition.vue

+ 18 - 13
src/components/CesiumTransition.vue

@@ -196,21 +196,26 @@ export default {
         });
 
         this._viewer.cesiumWidget.creditContainer.style.display = "none";
+      }
 
-        const scene = this._viewer.scene;
-        scene.fog.enabled = false;
-        scene.skyAtmosphere.show = false;
-        scene.globe.showGroundAtmosphere = false;
-        scene.globe.enableLighting = true;
-        scene.globe.tileCacheSize = 300;
-        scene.globe.maximumScreenSpaceError = 1.5;
-
-        this._viewer.clock.currentTime = Cesium.JulianDate.fromDate(new Date('2024-01-01T23:30:00Z'));
-        this._viewer.clock.shouldAnimate = false;
-
-        const baseLayer = this._viewer.imageryLayers.get(0);
-        if (baseLayer) { baseLayer.brightness = 0.45; baseLayer.contrast = 1.3; }
+      const scene = this._viewer.scene;
+      scene.fog.enabled = false;
+      scene.skyAtmosphere.show = false;
+      scene.globe.showGroundAtmosphere = false;
+      scene.globe.enableLighting = true;
+      scene.globe.tileCacheSize = 300;
+      scene.globe.maximumScreenSpaceError = 1.5;
+
+      this._viewer.clock.currentTime = Cesium.JulianDate.fromDate(new Date('2026-01-01T01:30:00Z'));
+      this._viewer.clock.shouldAnimate = false;
+
+      const baseLayer = this._viewer.imageryLayers.get(0);
+      if (baseLayer) { 
+        baseLayer.brightness = 0.75; // 亮度:1.0 是原图,小于 1.0 变暗,大于 1.0 变亮
+        baseLayer.contrast = 1.3;    // 对比度
+        baseLayer.gamma = 1; // 新增这一行:默认值是 1.0,调高可以显著提亮暗部环境
       }
+      
 
       const cam = this._viewer.scene.screenSpaceCameraController;
       cam.enableRotate = false;