mars3d-supermap 3.8.15 → 3.9.1
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 +1 -2
- package/mars3d-supermap.js +8 -10
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -47,8 +47,7 @@ import * as mars3d from "mars3d";
|
|
|
47
47
|
import "mars3d-supermap";
|
|
48
48
|
```
|
|
49
49
|
|
|
50
|
-
> 关于引入后的具体如何使用,请参考教程[
|
|
51
|
-
|
|
50
|
+
> 关于引入后的具体如何使用,请参考教程[Mars3D集成到项目](http://mars3d.cn/docs/guide/npm-integration/)中了解更多信息。
|
|
52
51
|
|
|
53
52
|
|
|
54
53
|
|
package/mars3d-supermap.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Mars3D平台插件,结合supermap超图库使用的功能插件 mars3d-supermap
|
|
3
3
|
*
|
|
4
|
-
* 版本信息:v3.
|
|
5
|
-
* 编译日期:2025-02-
|
|
4
|
+
* 版本信息:v3.9.1
|
|
5
|
+
* 编译日期:2025-02-25 22:13
|
|
6
6
|
* 版权所有:Copyright by 火星科技 http://mars3d.cn
|
|
7
|
-
* 使用单位:火星科技免费公开版 ,
|
|
7
|
+
* 使用单位:火星科技免费公开版 ,2025-02-01
|
|
8
8
|
*/
|
|
9
9
|
(function (global, factory) {
|
|
10
10
|
typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, (window.mars3d || require('mars3d'))) :
|
|
@@ -120,17 +120,17 @@
|
|
|
120
120
|
throw new Error("请引入 超图版本Cesium库 或 超图S3M插件 ");
|
|
121
121
|
}
|
|
122
122
|
const centerOld = this._map.getCameraView();
|
|
123
|
-
|
|
123
|
+
const url = this.getUrl();
|
|
124
124
|
// 场景添加S3M图层服务
|
|
125
125
|
let promise;
|
|
126
126
|
if (this.options.layername) {
|
|
127
|
-
promise = this._map.scene.addS3MTilesLayerByScp(
|
|
127
|
+
promise = this._map.scene.addS3MTilesLayerByScp(url, {
|
|
128
128
|
name: this.options.layername,
|
|
129
129
|
autoSetView: this.options.flyTo,
|
|
130
130
|
cullEnabled: this.options.cullEnabled
|
|
131
131
|
});
|
|
132
132
|
} else {
|
|
133
|
-
promise = this._map.scene.open(
|
|
133
|
+
promise = this._map.scene.open(url, this.options.sceneName, {
|
|
134
134
|
autoSetView: this.options.flyTo
|
|
135
135
|
});
|
|
136
136
|
}
|
|
@@ -312,7 +312,6 @@
|
|
|
312
312
|
* @param {ChinaCRS} [options.chinaCRS] 标识瓦片的国内坐标系(用于自动纠偏或加偏),自动将瓦片转为map对应的chinaCRS类型坐标系。
|
|
313
313
|
*
|
|
314
314
|
* @param {string} [options.proxy] 加载资源时要使用的代理服务url。
|
|
315
|
-
* @param {object} [options.templateValues] 一个对象,用于替换Url中的模板值的键/值对
|
|
316
315
|
* @param {object} [options.queryParameters] 一个对象,其中包含在检索资源时将发送的查询参数。比如:queryParameters: {'access_token': '123-435-456-000'},
|
|
317
316
|
* @param {object} [options.headers] 一个对象,将发送的其他HTTP标头。比如:headers: { 'X-My-Header': 'valueOfHeader' },
|
|
318
317
|
* @param {boolean} [options.enablePickFeatures=true] 如果为true,则 {@link UrlTemplateImageryProvider#pickFeatures} 请求 pickFeaturesUrl 并尝试解释响应中包含的功能。
|
|
@@ -462,13 +461,12 @@
|
|
|
462
461
|
// // }
|
|
463
462
|
// })
|
|
464
463
|
|
|
465
|
-
const
|
|
466
|
-
const handler = new Cesium.ScreenSpaceEventHandler(scene.canvas);
|
|
464
|
+
const handler = new Cesium.ScreenSpaceEventHandler(this._map.scene.canvas);
|
|
467
465
|
handler.setInputAction(event => {
|
|
468
466
|
if (!this.show) {
|
|
469
467
|
return;
|
|
470
468
|
}
|
|
471
|
-
const position =
|
|
469
|
+
const position = this._map.getCurrentMousePosition(event.position);
|
|
472
470
|
|
|
473
471
|
// 查询出相交图层的feature
|
|
474
472
|
const features = this._mvtLayer.queryRenderedFeatures([position], {
|
package/package.json
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mars3d-supermap",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.9.1",
|
|
4
4
|
"description": "Mars3D平台插件,结合supermap超图库使用的功能插件",
|
|
5
5
|
"main": "./mars3d-supermap.js",
|
|
6
6
|
"peerDependencies": {},
|
|
7
7
|
"devDependencies": {
|
|
8
|
-
"mars3d": "~3.
|
|
8
|
+
"mars3d": "~3.9.1"
|
|
9
9
|
},
|
|
10
10
|
"scripts": {
|
|
11
11
|
"lint": "eslint ./src/**/*.{js,ts} --fix"
|