@antv/l7-scene 2.20.5 → 2.20.6
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/es/ILayerManager.d.ts +1 -1
- package/es/IMapController.d.ts +1 -1
- package/es/IPostProcessingPassPluggable.d.ts +1 -1
- package/es/boxSelect.d.ts +1 -1
- package/es/index.d.ts +8 -6
- package/es/index.js +11 -3
- package/lib/index.js +8 -2
- package/package.json +9 -9
package/es/ILayerManager.d.ts
CHANGED
package/es/IMapController.d.ts
CHANGED
package/es/boxSelect.d.ts
CHANGED
package/es/index.d.ts
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { Bounds, ICameraOptions, IControl, IDebugService, IIconFontGlyph, IImage, ILayer, ILngLat, IMapService, IMarker, IMarkerLayer, IPoint, IPopup, IPostProcessingPass, ISceneConfig, IStatusOptions, Point } from '@antv/l7-core';
|
|
2
|
-
import { IProtocolHandler } from '@antv/l7-utils';
|
|
3
|
-
import { Container } from 'inversify';
|
|
4
|
-
import ILayerManager from './ILayerManager';
|
|
5
|
-
import IMapController from './IMapController';
|
|
6
|
-
import IPostProcessingPassPluggable from './IPostProcessingPassPluggable';
|
|
1
|
+
import type { Bounds, ICameraOptions, IControl, IDebugService, IIconFontGlyph, IImage, ILayer, ILngLat, IMapService, IMarker, IMarkerLayer, IPoint, IPopup, IPostProcessingPass, ISceneConfig, IStatusOptions, Point } from '@antv/l7-core';
|
|
2
|
+
import type { IProtocolHandler } from '@antv/l7-utils';
|
|
3
|
+
import type { Container } from 'inversify';
|
|
4
|
+
import type ILayerManager from './ILayerManager';
|
|
5
|
+
import type IMapController from './IMapController';
|
|
6
|
+
import type IPostProcessingPassPluggable from './IPostProcessingPassPluggable';
|
|
7
7
|
/**
|
|
8
8
|
* 暴露 Scene API
|
|
9
9
|
*
|
|
@@ -122,6 +122,8 @@ declare class Scene implements IPostProcessingPassPluggable, IMapController, ILa
|
|
|
122
122
|
static addProtocol(protocol: string, handler: IProtocolHandler): void;
|
|
123
123
|
static removeProtocol(protocol: string): void;
|
|
124
124
|
getProtocol(protocol: string): IProtocolHandler;
|
|
125
|
+
startAnimate(): void;
|
|
126
|
+
stopAnimate(): void;
|
|
125
127
|
getPointSizeRange(): Float32Array;
|
|
126
128
|
private initComponent;
|
|
127
129
|
private initControl;
|
package/es/index.js
CHANGED
|
@@ -28,15 +28,13 @@ var Scene = /*#__PURE__*/function () {
|
|
|
28
28
|
var id = config.id,
|
|
29
29
|
map = config.map,
|
|
30
30
|
canvas = config.canvas,
|
|
31
|
-
hasBaseMap = config.hasBaseMap,
|
|
32
31
|
_config$renderer = config.renderer,
|
|
33
32
|
renderer = _config$renderer === void 0 ? 'regl' : _config$renderer;
|
|
34
33
|
// 创建场景容器
|
|
35
34
|
var sceneContainer = createSceneContainer();
|
|
36
35
|
this.container = sceneContainer;
|
|
37
36
|
// 绑定地图服务
|
|
38
|
-
map.setContainer(sceneContainer, id, canvas
|
|
39
|
-
|
|
37
|
+
map.setContainer(sceneContainer, id, canvas);
|
|
40
38
|
// 绑定渲染引擎服务
|
|
41
39
|
sceneContainer.bind(TYPES.IRendererService).to(renderer === 'regl' ? ReglRendererService : DeviceRendererService).inSingletonScope();
|
|
42
40
|
|
|
@@ -642,6 +640,16 @@ var Scene = /*#__PURE__*/function () {
|
|
|
642
640
|
value: function getProtocol(protocol) {
|
|
643
641
|
return SceneConifg.REGISTERED_PROTOCOLS[protocol];
|
|
644
642
|
}
|
|
643
|
+
}, {
|
|
644
|
+
key: "startAnimate",
|
|
645
|
+
value: function startAnimate() {
|
|
646
|
+
this.layerService.startAnimate();
|
|
647
|
+
}
|
|
648
|
+
}, {
|
|
649
|
+
key: "stopAnimate",
|
|
650
|
+
value: function stopAnimate() {
|
|
651
|
+
this.layerService.stopAnimate();
|
|
652
|
+
}
|
|
645
653
|
|
|
646
654
|
// get current point size info
|
|
647
655
|
}, {
|
package/lib/index.js
CHANGED
|
@@ -40,10 +40,10 @@ var import_l7_utils = require("@antv/l7-utils");
|
|
|
40
40
|
var import_boxSelect = __toESM(require("./boxSelect"));
|
|
41
41
|
var Scene = class {
|
|
42
42
|
constructor(config) {
|
|
43
|
-
const { id, map, canvas,
|
|
43
|
+
const { id, map, canvas, renderer = "regl" } = config;
|
|
44
44
|
const sceneContainer = (0, import_l7_core.createSceneContainer)();
|
|
45
45
|
this.container = sceneContainer;
|
|
46
|
-
map.setContainer(sceneContainer, id, canvas
|
|
46
|
+
map.setContainer(sceneContainer, id, canvas);
|
|
47
47
|
sceneContainer.bind(import_l7_core.TYPES.IRendererService).to(renderer === "regl" ? import_l7_renderer.ReglRendererService : import_l7_renderer.DeviceRendererService).inSingletonScope();
|
|
48
48
|
this.sceneService = sceneContainer.get(import_l7_core.TYPES.ISceneService);
|
|
49
49
|
this.mapService = sceneContainer.get(
|
|
@@ -408,6 +408,12 @@ var Scene = class {
|
|
|
408
408
|
getProtocol(protocol) {
|
|
409
409
|
return import_l7_utils.SceneConifg.REGISTERED_PROTOCOLS[protocol];
|
|
410
410
|
}
|
|
411
|
+
startAnimate() {
|
|
412
|
+
this.layerService.startAnimate();
|
|
413
|
+
}
|
|
414
|
+
stopAnimate() {
|
|
415
|
+
this.layerService.stopAnimate();
|
|
416
|
+
}
|
|
411
417
|
// get current point size info
|
|
412
418
|
getPointSizeRange() {
|
|
413
419
|
return this.sceneService.getPointSizeRange();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@antv/l7-scene",
|
|
3
|
-
"version": "2.20.
|
|
3
|
+
"version": "2.20.6",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "lib/index.js",
|
|
6
6
|
"module": "es/index.js",
|
|
@@ -23,12 +23,12 @@
|
|
|
23
23
|
"author": "xiaoiver",
|
|
24
24
|
"license": "ISC",
|
|
25
25
|
"dependencies": {
|
|
26
|
-
"@antv/l7-component": "2.20.
|
|
27
|
-
"@antv/l7-core": "2.20.
|
|
28
|
-
"@antv/l7-layers": "2.20.
|
|
29
|
-
"@antv/l7-maps": "2.20.
|
|
30
|
-
"@antv/l7-renderer": "2.20.
|
|
31
|
-
"@antv/l7-utils": "2.20.
|
|
26
|
+
"@antv/l7-component": "2.20.6",
|
|
27
|
+
"@antv/l7-core": "2.20.6",
|
|
28
|
+
"@antv/l7-layers": "2.20.6",
|
|
29
|
+
"@antv/l7-maps": "2.20.6",
|
|
30
|
+
"@antv/l7-renderer": "2.20.6",
|
|
31
|
+
"@antv/l7-utils": "2.20.6",
|
|
32
32
|
"@babel/runtime": "^7.7.7",
|
|
33
33
|
"eventemitter3": "^4.0.7",
|
|
34
34
|
"inversify": "^5.0.1",
|
|
@@ -36,9 +36,9 @@
|
|
|
36
36
|
"reflect-metadata": "^0.1.13"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
|
-
"@antv/l7-test-utils": "2.20.
|
|
39
|
+
"@antv/l7-test-utils": "2.20.6"
|
|
40
40
|
},
|
|
41
|
-
"gitHead": "
|
|
41
|
+
"gitHead": "b5af1f23f8f5524cbbb2ea858399fefba63b0163",
|
|
42
42
|
"publishConfig": {
|
|
43
43
|
"access": "public"
|
|
44
44
|
}
|