| @@ -1,5 +1,12 @@ | |||
| # 更新 | |||
| ## 1.8.1 | |||
| ### 2020-7-20 | |||
| > 1. 添加地球基础颜色的设置 | |||
| > 2. 添加 3D 场景销毁功能 | |||
| ## 1.8.0 | |||
| ### 2020-7-2 | |||
| @@ -1,6 +1,6 @@ | |||
| { | |||
| "name": "@dvgis/dc-sdk", | |||
| "version": "1.8.0", | |||
| "version": "1.8.1", | |||
| "description": " The SDK is a secondary development based on the open source project Cesium, which optimizes some operations of Cesium and enables developers to quickly develop 3D applications through the framework.", | |||
| "main": "index.js", | |||
| "repository": "https://github.com/Digital-Visual/dc-sdk.git", | |||
| @@ -2,7 +2,7 @@ | |||
| * @Author: Caven | |||
| * @Date: 2019-12-30 09:24:37 | |||
| * @Last Modified by: Caven | |||
| * @Last Modified time: 2020-06-09 09:57:50 | |||
| * @Last Modified time: 2020-07-20 10:15:24 | |||
| */ | |||
| import { Util } from '../utils' | |||
| @@ -29,6 +29,7 @@ class ViewerOption { | |||
| _setViewerOption() { | |||
| this._viewer.delegate.shadows = this._options.shadows ?? false | |||
| this._viewer.delegate.resolutionScale = this._options.resolutionScale || 1.0 | |||
| return this | |||
| } | |||
| @@ -76,7 +77,8 @@ class ViewerOption { | |||
| show: globeOption?.show ?? true, | |||
| enableLighting: globeOption?.enableLighting ?? false, | |||
| depthTestAgainstTerrain: globeOption?.undergroundMode ?? false, | |||
| tileCacheSize: +globeOption?.tileCacheSize || 100 | |||
| tileCacheSize: +globeOption?.tileCacheSize || 100, | |||
| baseColor: globeOption?.baseColor || new Cesium.Color(0, 0, 0.5, 1) | |||
| }) | |||
| Util.merge(globe.translucency, { | |||
| @@ -2,7 +2,7 @@ | |||
| * @Author: Caven | |||
| * @Date: 2019-12-27 17:13:24 | |||
| * @Last Modified by: Caven | |||
| * @Last Modified time: 2020-06-28 10:14:50 | |||
| * @Last Modified time: 2020-07-20 09:41:26 | |||
| */ | |||
| import { | |||
| @@ -580,6 +580,14 @@ class Viewer { | |||
| return this | |||
| } | |||
| /** | |||
| * destroys the viewer. | |||
| */ | |||
| destroy() { | |||
| this._delegate.destroy() | |||
| return this | |||
| } | |||
| /** | |||
| * | |||
| * @param {*} plugin | |||