diff --git a/src/Obj/Base/TrajectoryMotion/index.js b/src/Obj/Base/TrajectoryMotion/index.js index aefb9dc..7256780 100644 --- a/src/Obj/Base/TrajectoryMotion/index.js +++ b/src/Obj/Base/TrajectoryMotion/index.js @@ -1764,9 +1764,10 @@ class TrajectoryMotion extends Base { if (!cartesian3) { return } - coordinates = _this.cartesian3Towgs84(cartesian3, viewer); + let pos84 = _this.cartesian3Towgs84(cartesian3, viewer); + coordinates = [pos84.lng, pos84.lat, pos84.alt + 1.8] position = cartesian3 - positionCamera = Cesium.Cartesian3.fromDegrees(coordinates.lng, coordinates.lat, coordinates.alt + 1.8) + positionCamera = Cesium.Cartesian3.fromDegrees(coordinates[0], coordinates[1], coordinates[2]) let positions_smooth = [] for (let i = 0; i <= 1000; i++) { if ((i / 1000) > (distance / _this.distance)) { @@ -1890,7 +1891,7 @@ class TrajectoryMotion extends Base { else { if (_this.sdk.viewer.trackedEntity) { _this.sdk.viewer.camera.setView({ - destination: Cesium.Cartesian3.fromDegrees(coordinates.lng, coordinates.lat, _this.sdk.viewer.camera.positionCartographic.height), + destination: Cesium.Cartesian3.fromDegrees(coordinates[0], coordinates[1], _this.sdk.viewer.camera.positionCartographic.height), orientation: { heading: Cesium.Math.toRadians(-90), pitch: 0, diff --git a/src/YJEarth/index.js b/src/YJEarth/index.js index 775f153..b959df3 100644 --- a/src/YJEarth/index.js +++ b/src/YJEarth/index.js @@ -151,7 +151,7 @@ class YJEarth { } this.options.contextOptions = { webgl: { - alpha: true, + // alpha: true, depth: true, stencil: true, antialias: true,