cesium_dev_kit 1.0.72 → 1.0.74
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +34 -14
- package/dist/index.js +2 -2
- package/dist/index.min.js +2 -2
- package/dist/index.umd.js +2 -2
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -33,13 +33,13 @@
|
|
|
33
33
|
## 安装
|
|
34
34
|
|
|
35
35
|
```shell
|
|
36
|
-
|
|
36
|
+
npm install cesium_dev_kit
|
|
37
37
|
```
|
|
38
38
|
|
|
39
39
|
## 引入
|
|
40
40
|
|
|
41
41
|
```
|
|
42
|
-
|
|
42
|
+
import { initCesium } from 'cesium_dev_kit'
|
|
43
43
|
```
|
|
44
44
|
|
|
45
45
|
## 使用
|
|
@@ -50,20 +50,22 @@
|
|
|
50
50
|
|
|
51
51
|
### 1.1 initCesium 参数配置
|
|
52
52
|
|
|
53
|
-
| Property
|
|
54
|
-
|
|
|
55
|
-
| cesiumGlobal
|
|
56
|
-
|
|
|
57
|
-
|
|
|
58
|
-
|
|
|
59
|
-
|
|
|
60
|
-
|
|
|
53
|
+
| Property | Type | Description | Default |
|
|
54
|
+
| ---------------- | ------ | ----------------------------------------------------------------------------- | --------- |
|
|
55
|
+
| cesiumGlobal | Object | Cesium 对象 | undefined |
|
|
56
|
+
| threeGlobal | Object | THREE 对象 | undefined |
|
|
57
|
+
| containerId | String | Cesium 挂载 dom 容器 id | undefined |
|
|
58
|
+
| threeContainerId | String | Three 挂载 dom 容器 id | undefined |
|
|
59
|
+
| viewerConfig | Object | viewer 基础配置(与官网一致) | {} |
|
|
60
|
+
| extreaConfig | Object | 额外参数配置,如 {logo:true// 是否显示 logo, depthTest:true //开启深度检测} | {} |
|
|
61
|
+
| MapImageryList | Array | 配置底图,参考 ImageryProvider | [] |
|
|
62
|
+
| defaultStatic | Array | 着色器使用的静态资源配置(如图片 url) | undefined |
|
|
61
63
|
|
|
62
64
|
### 1.2 initCesium 返回对象
|
|
63
65
|
|
|
64
66
|
| name | Type | Description |
|
|
65
67
|
| ------------------ | ------ | ------------------------------------------------ |
|
|
66
|
-
| viewer | Object |
|
|
68
|
+
| viewer | Object | Cesium 实例对象 |
|
|
67
69
|
| material | Object | 材质模块(修改实体材质) |
|
|
68
70
|
| graphics | Object | 图形模块(如创建 PolygonGraphics 对象等) |
|
|
69
71
|
| math3d | Object | 三维数学工具 |
|
|
@@ -78,6 +80,7 @@
|
|
|
78
80
|
| attackArrowObj | Object | 标绘(攻击) |
|
|
79
81
|
| straightArrowObj | Object | 标绘(直击) |
|
|
80
82
|
| pincerArrowObj | Object | 标绘(钳击) |
|
|
83
|
+
| ThreeJs | Object | 集成 ThreeJS 扩展对象 |
|
|
81
84
|
|
|
82
85
|
### 1.3 使用案例
|
|
83
86
|
|
|
@@ -138,7 +141,7 @@ export default {
|
|
|
138
141
|
可根据功能需求导出单一扩展类,减少代码冗余
|
|
139
142
|
|
|
140
143
|
```javaScript
|
|
141
|
-
import {Graphics, Material,Primitive,Draw,Analysis,CustomCesiumPlugin,PassEffect,Plugin} from 'cesium_dev_kit'
|
|
144
|
+
import {Graphics, Material,Primitive,Draw,Analysis,CustomCesiumPlugin,PassEffect,Plugin,ThreeJs} from 'cesium_dev_kit'
|
|
142
145
|
```
|
|
143
146
|
|
|
144
147
|
### 2.1 扩展类:
|
|
@@ -151,6 +154,7 @@ export default {
|
|
|
151
154
|
- CustomCesiumPlugin: 自定义相控扩展
|
|
152
155
|
- PassEffect: 后期特效对象
|
|
153
156
|
- Plugin: 各种扩展功能
|
|
157
|
+
- ThreeJs: 集成 ThreeJS 扩展对象
|
|
154
158
|
|
|
155
159
|
### 2.2 Draw 使用案例:
|
|
156
160
|
|
|
@@ -220,13 +224,13 @@ export default {
|
|
|
220
224
|
- html 中直接引入 index.umd.js
|
|
221
225
|
|
|
222
226
|
```javaScript
|
|
223
|
-
|
|
227
|
+
<script type="text/javascript" src="index.umd.js"></script>
|
|
224
228
|
```
|
|
225
229
|
|
|
226
230
|
- 初始化对象
|
|
227
231
|
|
|
228
232
|
```javaScript
|
|
229
|
-
|
|
233
|
+
new cesium_dev_kit.initCesium({...})
|
|
230
234
|
```
|
|
231
235
|
|
|
232
236
|
## 使用范例
|
|
@@ -261,6 +265,18 @@ export default {
|
|
|
261
265
|
|
|
262
266
|
<small>欢迎感兴趣朋友加入一起完善功能,让工作效更高效、开发更简单、生活更惬意。</small>
|
|
263
267
|
|
|
268
|
+
## `Star`
|
|
269
|
+
|
|
270
|
+
非常感谢留下星星的好心人,感谢您的支持 :heart:
|
|
271
|
+
|
|
272
|
+
[![Stargazers repo roster for @dengxiaoning/cesium_dev_kit][stargazers-url]][stargazers-link]
|
|
273
|
+
|
|
274
|
+
## `Fork`
|
|
275
|
+
|
|
276
|
+
@sincely、`@ooil929`、 @InPanda、 `luyufanzhi`、AllenChiangCN、`Liquid-Zhangliquan` :heart:
|
|
277
|
+
|
|
278
|
+
[![Forkers repo roster for @dengxiaoning/cesium_dev_kit][forkers-url]][forkers-link]
|
|
279
|
+
|
|
264
280
|
[npm]: https://img.shields.io/npm/v/cesium_dev_kit
|
|
265
281
|
[npm-url]: https://www.npmjs.com/package/cesium_dev_kit
|
|
266
282
|
[build-size]: https://img.shields.io/bundlephobia/minzip/cesium_dev_kit/1.0.70?logo=travis
|
|
@@ -272,3 +288,7 @@ export default {
|
|
|
272
288
|
[build-status]: https://github.com/dengxiaoning/cesium_dev_kit
|
|
273
289
|
[build-main]: https://img.shields.io/github/actions/workflow/status/dengxiaoning/cesium_dev_kit/project-build.yml?branch=main&logo=github
|
|
274
290
|
[repo-stars]: https://img.shields.io/github/stars/dengxiaoning/cesium_dev_kit?style=plastic&logo=github
|
|
291
|
+
[forkers-url]: https://bytecrank.com/nastyox/reporoster/php/forkersSVG.php?user=dengxiaoning&repo=cesium_dev_kit
|
|
292
|
+
[forkers-link]: https://github.com/dengxiaoning/cesium_dev_kit/network/members
|
|
293
|
+
[stargazers-url]: https://bytecrank.com/nastyox/reporoster/php/stargazersSVG.php?user=dengxiaoning&repo=cesium_dev_kit
|
|
294
|
+
[stargazers-link]: https://github.com/dengxiaoning/cesium_dev_kit/stargazers
|