@antv/l7-layers 2.10.2 → 2.10.3
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/Geometry/index.js +8 -8
- package/es/Geometry/models/billboard.js +9 -9
- package/es/Geometry/models/plane.js +10 -10
- package/es/Geometry/models/sprite.js +10 -10
- package/es/canvas/index.js +8 -8
- package/es/canvas/models/canvas.js +9 -9
- package/es/citybuliding/building.js +8 -8
- package/es/citybuliding/models/build.js +7 -7
- package/es/core/BaseLayer.js +37 -46
- package/es/core/BaseModel.js +8 -8
- package/es/core/LayerPickService.js +4 -4
- package/es/core/shape/Path.js +1 -1
- package/es/core/shape/extrude.js +1 -1
- package/es/core/triangulation.js +2 -2
- package/es/earth/index.js +8 -8
- package/es/earth/models/atmosphere.js +6 -6
- package/es/earth/models/base.js +8 -8
- package/es/earth/models/bloomsphere.js +6 -6
- package/es/earth/utils.js +1 -1
- package/es/heatmap/index.js +8 -8
- package/es/heatmap/models/grid.js +6 -6
- package/es/heatmap/models/grid3d.js +6 -6
- package/es/heatmap/models/heatmap.js +8 -8
- package/es/heatmap/models/hexagon.js +6 -6
- package/es/image/index.js +8 -8
- package/es/image/models/dataImage.js +6 -6
- package/es/image/models/image.js +6 -6
- package/es/image/models/tileDataImage.js +6 -6
- package/es/line/index.js +9 -9
- package/es/line/models/arc.js +8 -8
- package/es/line/models/arc_3d.js +8 -8
- package/es/line/models/earthArc_3d.js +8 -8
- package/es/line/models/great_circle.js +8 -8
- package/es/line/models/half.js +6 -6
- package/es/line/models/line.js +8 -8
- package/es/line/models/linearline.js +8 -8
- package/es/line/models/simpleLine.js +6 -6
- package/es/line/models/simpleTileLine.js +6 -6
- package/es/line/models/tile.js +6 -6
- package/es/line/models/wall.js +8 -8
- package/es/mask/index.js +8 -8
- package/es/mask/models/fill.js +6 -6
- package/es/plugins/DataMappingPlugin.d.ts +0 -2
- package/es/plugins/DataMappingPlugin.js +24 -97
- package/es/plugins/DataSourcePlugin.js +27 -19
- package/es/plugins/FeatureScalePlugin.d.ts +0 -1
- package/es/plugins/FeatureScalePlugin.js +7 -23
- package/es/plugins/LayerAnimateStylePlugin.js +3 -3
- package/es/plugins/LayerModelPlugin.js +4 -7
- package/es/plugins/LayerStylePlugin.js +2 -2
- package/es/plugins/LightingPlugin.js +4 -4
- package/es/plugins/MultiPassRendererPlugin.js +2 -2
- package/es/plugins/PixelPickingPlugin.js +2 -2
- package/es/plugins/RegisterStyleAttributePlugin.js +2 -2
- package/es/plugins/ShaderUniformPlugin.js +6 -6
- package/es/plugins/UpdateModelPlugin.js +5 -2
- package/es/plugins/UpdateStyleAttributePlugin.js +3 -7
- package/es/point/index.js +8 -8
- package/es/point/models/earthExtrude.js +8 -8
- package/es/point/models/earthFill.js +8 -8
- package/es/point/models/extrude.js +8 -8
- package/es/point/models/fill.js +9 -9
- package/es/point/models/fillmage.js +9 -9
- package/es/point/models/image.js +8 -8
- package/es/point/models/normal.js +7 -7
- package/es/point/models/radar.js +9 -9
- package/es/point/models/simplePoint.js +7 -7
- package/es/point/models/text.js +45 -29
- package/es/point/models/tile.js +6 -6
- package/es/point/models/tileText.js +9 -9
- package/es/point/shape/extrude.js +1 -1
- package/es/polygon/index.js +8 -8
- package/es/polygon/models/extrude.js +7 -7
- package/es/polygon/models/fill.js +6 -6
- package/es/polygon/models/ocean.js +7 -7
- package/es/polygon/models/tile.js +6 -6
- package/es/polygon/models/water.js +7 -7
- package/es/raster/index.js +8 -8
- package/es/raster/models/raster.js +6 -6
- package/es/raster/models/rasterRgb.js +8 -8
- package/es/raster/models/rasterTile.js +6 -6
- package/es/raster/raster.js +10 -10
- package/es/tile/interaction/getRasterData.js +1 -1
- package/es/tile/interaction/utils.js +1 -1
- package/es/tile/manager/base.js +5 -5
- package/es/tile/service/TileLayerService.js +5 -5
- package/es/tile/service/TilePickService.d.ts +3 -3
- package/es/tile/service/TilePickService.js +31 -7
- package/es/tile/service/TileSourceService.d.ts +7 -0
- package/es/tile/service/TileSourceService.js +39 -0
- package/es/tile/style/utils.js +1 -1
- package/es/tile/tileFactory/DebugTile.js +6 -6
- package/es/tile/tileFactory/ImageTile.js +7 -7
- package/es/tile/tileFactory/MaskTile.js +8 -8
- package/es/tile/tileFactory/RasterRGBTile.js +7 -7
- package/es/tile/tileFactory/RasterTile.js +7 -7
- package/es/tile/tileFactory/Tile.d.ts +11 -0
- package/es/tile/tileFactory/Tile.js +68 -5
- package/es/tile/tileFactory/VectorTile.d.ts +1 -1
- package/es/tile/tileFactory/VectorTile.js +8 -14
- package/es/tile/tileFactory/layers/RasterDataLayer.js +8 -8
- package/es/tile/tileFactory/layers/TileDebugLayer.js +8 -8
- package/es/tile/tileLayer/BaseLayer.js +4 -4
- package/es/utils/blend.js +1 -1
- package/es/utils/collision-index.js +4 -4
- package/es/utils/extrude_polyline.js +5 -5
- package/es/utils/grid-index.js +3 -3
- package/es/utils/multiPassRender.js +1 -1
- package/es/utils/polylineNormal.js +1 -1
- package/es/utils/simpleLine.js +3 -3
- package/es/wind/index.js +8 -8
- package/es/wind/models/wind.js +11 -8
- package/es/wind/models/windRender.js +3 -3
- package/lib/core/BaseLayer.js +24 -33
- package/lib/plugins/DataMappingPlugin.js +16 -87
- package/lib/plugins/DataSourcePlugin.js +24 -16
- package/lib/plugins/FeatureScalePlugin.js +2 -18
- package/lib/plugins/LayerModelPlugin.js +1 -4
- package/lib/plugins/UpdateModelPlugin.js +3 -0
- package/lib/plugins/UpdateStyleAttributePlugin.js +1 -5
- package/lib/point/models/text.js +36 -20
- package/lib/tile/service/TilePickService.js +29 -3
- package/lib/tile/service/TileSourceService.js +59 -0
- package/lib/tile/tileFactory/MaskTile.js +1 -1
- package/lib/tile/tileFactory/Tile.js +64 -0
- package/lib/tile/tileFactory/VectorTile.js +1 -7
- package/lib/wind/models/wind.js +3 -0
- package/package.json +6 -6
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
2
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
3
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
4
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
5
|
-
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
6
|
-
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
1
|
+
import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
|
|
2
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
3
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
4
|
+
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
5
|
+
import _possibleConstructorReturn from "@babel/runtime/helpers/esm/possibleConstructorReturn";
|
|
6
|
+
import _getPrototypeOf from "@babel/runtime/helpers/esm/getPrototypeOf";
|
|
7
7
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
8
8
|
|
|
9
9
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import _objectSpread from "@babel/runtime/helpers/objectSpread2";
|
|
2
|
-
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
3
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
4
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
5
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
6
|
-
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
7
|
-
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
1
|
+
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
2
|
+
import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
|
|
3
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
4
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
5
|
+
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
6
|
+
import _possibleConstructorReturn from "@babel/runtime/helpers/esm/possibleConstructorReturn";
|
|
7
|
+
import _getPrototypeOf from "@babel/runtime/helpers/esm/getPrototypeOf";
|
|
8
8
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
9
9
|
|
|
10
10
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import _objectSpread from "@babel/runtime/helpers/objectSpread2";
|
|
2
|
-
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
3
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
4
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
5
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
6
|
-
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
7
|
-
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
1
|
+
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
2
|
+
import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
|
|
3
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
4
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
5
|
+
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
6
|
+
import _possibleConstructorReturn from "@babel/runtime/helpers/esm/possibleConstructorReturn";
|
|
7
|
+
import _getPrototypeOf from "@babel/runtime/helpers/esm/getPrototypeOf";
|
|
8
8
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
9
9
|
|
|
10
10
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -75,7 +75,7 @@ var MaskTile = /*#__PURE__*/function (_Tile) {
|
|
|
75
75
|
sourceLayer = _this$parent$getLayer.sourceLayer,
|
|
76
76
|
featureId = _this$parent$getLayer.featureId;
|
|
77
77
|
|
|
78
|
-
var features = this.
|
|
78
|
+
var features = this.getFeatures(sourceLayer);
|
|
79
79
|
return {
|
|
80
80
|
data: {
|
|
81
81
|
type: 'FeatureCollection',
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import _objectSpread from "@babel/runtime/helpers/objectSpread2";
|
|
2
|
-
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
3
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
4
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
5
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
6
|
-
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
7
|
-
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
1
|
+
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
2
|
+
import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
|
|
3
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
4
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
5
|
+
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
6
|
+
import _possibleConstructorReturn from "@babel/runtime/helpers/esm/possibleConstructorReturn";
|
|
7
|
+
import _getPrototypeOf from "@babel/runtime/helpers/esm/getPrototypeOf";
|
|
8
8
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
9
9
|
|
|
10
10
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import _objectSpread from "@babel/runtime/helpers/objectSpread2";
|
|
2
|
-
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
3
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
4
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
5
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
6
|
-
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
7
|
-
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
1
|
+
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
2
|
+
import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
|
|
3
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
4
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
5
|
+
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
6
|
+
import _possibleConstructorReturn from "@babel/runtime/helpers/esm/possibleConstructorReturn";
|
|
7
|
+
import _getPrototypeOf from "@babel/runtime/helpers/esm/getPrototypeOf";
|
|
8
8
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
9
9
|
|
|
10
10
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -19,5 +19,16 @@ export default abstract class Tile implements ITile {
|
|
|
19
19
|
protected addLayer(layer: ILayer): Promise<void>;
|
|
20
20
|
updateVisible(value: boolean): void;
|
|
21
21
|
updateOptions(key: string, value: any): void;
|
|
22
|
+
/**
|
|
23
|
+
* 一个 Tile 可能有多个 layer,但是在发生拾取、点击事件的时候只有一个生效
|
|
24
|
+
*/
|
|
25
|
+
getMainLayer(): ILayer | undefined;
|
|
26
|
+
getFeatures(sourceLayer: string | undefined): any;
|
|
27
|
+
/**
|
|
28
|
+
* 在一个 Tile 中可能存在一个相同 ID 的 feature
|
|
29
|
+
* @param id
|
|
30
|
+
* @returns
|
|
31
|
+
*/
|
|
32
|
+
getFeatureById(id: number): import("@antv/l7-core").IParseDataItem[];
|
|
22
33
|
destroy(): void;
|
|
23
34
|
}
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
1
|
+
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
2
|
+
import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
|
|
3
|
+
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
|
4
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
5
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
6
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
6
7
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
7
8
|
import { createLayerContainer } from '@antv/l7-core';
|
|
8
9
|
|
|
@@ -121,6 +122,68 @@ var Tile = /*#__PURE__*/function () {
|
|
|
121
122
|
l.updateLayerConfig(_defineProperty({}, key, value));
|
|
122
123
|
});
|
|
123
124
|
}
|
|
125
|
+
/**
|
|
126
|
+
* 一个 Tile 可能有多个 layer,但是在发生拾取、点击事件的时候只有一个生效
|
|
127
|
+
*/
|
|
128
|
+
|
|
129
|
+
}, {
|
|
130
|
+
key: "getMainLayer",
|
|
131
|
+
value: function getMainLayer() {
|
|
132
|
+
return this.layers[0];
|
|
133
|
+
}
|
|
134
|
+
}, {
|
|
135
|
+
key: "getFeatures",
|
|
136
|
+
value: function getFeatures(sourceLayer) {
|
|
137
|
+
var _this$sourceTile$data, _this$sourceTile$data2;
|
|
138
|
+
|
|
139
|
+
if (!sourceLayer || !((_this$sourceTile$data = this.sourceTile.data) !== null && _this$sourceTile$data !== void 0 && _this$sourceTile$data.layers[sourceLayer])) {
|
|
140
|
+
return [];
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
var vectorTile = (_this$sourceTile$data2 = this.sourceTile.data) === null || _this$sourceTile$data2 === void 0 ? void 0 : _this$sourceTile$data2.layers[sourceLayer];
|
|
144
|
+
|
|
145
|
+
if (Array.isArray(vectorTile.features)) {
|
|
146
|
+
// 数据不需要被解析 geojson-vt 类型
|
|
147
|
+
return vectorTile.features;
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
var _this$sourceTile = this.sourceTile,
|
|
151
|
+
x = _this$sourceTile.x,
|
|
152
|
+
y = _this$sourceTile.y,
|
|
153
|
+
z = _this$sourceTile.z;
|
|
154
|
+
var features = [];
|
|
155
|
+
|
|
156
|
+
for (var i = 0; i < vectorTile.length; i++) {
|
|
157
|
+
var vectorTileFeature = vectorTile.feature(i);
|
|
158
|
+
var feature = vectorTileFeature.toGeoJSON(x, y, z);
|
|
159
|
+
features.push(_objectSpread(_objectSpread({}, feature), {}, {
|
|
160
|
+
properties: _objectSpread({
|
|
161
|
+
id: feature.id
|
|
162
|
+
}, feature.properties)
|
|
163
|
+
}));
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
return features;
|
|
167
|
+
}
|
|
168
|
+
/**
|
|
169
|
+
* 在一个 Tile 中可能存在一个相同 ID 的 feature
|
|
170
|
+
* @param id
|
|
171
|
+
* @returns
|
|
172
|
+
*/
|
|
173
|
+
|
|
174
|
+
}, {
|
|
175
|
+
key: "getFeatureById",
|
|
176
|
+
value: function getFeatureById(id) {
|
|
177
|
+
var layer = this.getMainLayer();
|
|
178
|
+
|
|
179
|
+
if (!layer) {
|
|
180
|
+
return [];
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
return layer.getSource().data.dataArray.filter(function (d) {
|
|
184
|
+
return d._id === id;
|
|
185
|
+
});
|
|
186
|
+
}
|
|
124
187
|
}, {
|
|
125
188
|
key: "destroy",
|
|
126
189
|
value: function destroy() {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import _objectSpread from "@babel/runtime/helpers/objectSpread2";
|
|
2
|
-
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
3
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
4
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
5
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
6
|
-
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
7
|
-
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
1
|
+
import _objectSpread from "@babel/runtime/helpers/esm/objectSpread2";
|
|
2
|
+
import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
|
|
3
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
4
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
5
|
+
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
6
|
+
import _possibleConstructorReturn from "@babel/runtime/helpers/esm/possibleConstructorReturn";
|
|
7
|
+
import _getPrototypeOf from "@babel/runtime/helpers/esm/getPrototypeOf";
|
|
8
8
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
9
9
|
|
|
10
10
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -118,13 +118,7 @@ var VectorTile = /*#__PURE__*/function (_Tile) {
|
|
|
118
118
|
_this$parent$getLayer3 = _this$parent$getLayer.featureId,
|
|
119
119
|
featureId = _this$parent$getLayer3 === void 0 ? 'id' : _this$parent$getLayer3;
|
|
120
120
|
|
|
121
|
-
var
|
|
122
|
-
|
|
123
|
-
if (!vectorLayer) {
|
|
124
|
-
return false;
|
|
125
|
-
}
|
|
126
|
-
|
|
127
|
-
var features = vectorLayer.features;
|
|
121
|
+
var features = this.getFeatures(sourceLayer);
|
|
128
122
|
return {
|
|
129
123
|
data: {
|
|
130
124
|
type: 'FeatureCollection',
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
2
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
3
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
4
|
-
import _assertThisInitialized from "@babel/runtime/helpers/assertThisInitialized";
|
|
5
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
6
|
-
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
7
|
-
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
8
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
1
|
+
import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
|
|
2
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
3
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
4
|
+
import _assertThisInitialized from "@babel/runtime/helpers/esm/assertThisInitialized";
|
|
5
|
+
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
6
|
+
import _possibleConstructorReturn from "@babel/runtime/helpers/esm/possibleConstructorReturn";
|
|
7
|
+
import _getPrototypeOf from "@babel/runtime/helpers/esm/getPrototypeOf";
|
|
8
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
9
9
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
10
10
|
|
|
11
11
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
2
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
3
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
4
|
-
import _assertThisInitialized from "@babel/runtime/helpers/assertThisInitialized";
|
|
5
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
6
|
-
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
7
|
-
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
8
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
1
|
+
import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
|
|
2
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
3
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
4
|
+
import _assertThisInitialized from "@babel/runtime/helpers/esm/assertThisInitialized";
|
|
5
|
+
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
6
|
+
import _possibleConstructorReturn from "@babel/runtime/helpers/esm/possibleConstructorReturn";
|
|
7
|
+
import _getPrototypeOf from "@babel/runtime/helpers/esm/getPrototypeOf";
|
|
8
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
9
9
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
10
10
|
|
|
11
11
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
2
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
3
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
4
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
1
|
+
import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
|
|
2
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
3
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
4
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
5
5
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
6
6
|
import { TYPES } from '@antv/l7-core';
|
|
7
7
|
import { TileLayerService } from "../service/TileLayerService";
|
package/es/utils/blend.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
|
2
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
3
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
4
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
1
|
+
import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray";
|
|
2
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
3
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
4
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
5
5
|
// @mapbox/grid-index 并没有类似 hitTest 的单纯获取碰撞检测结果的方法,query 将导致计算大量多余的包围盒结果,因此使用改良版
|
|
6
6
|
import { mat4, vec4 } from 'gl-matrix';
|
|
7
7
|
import GridIndex from "./grid-index";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
2
|
-
import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
|
3
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
4
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
5
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
1
|
+
import _slicedToArray from "@babel/runtime/helpers/esm/slicedToArray";
|
|
2
|
+
import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray";
|
|
3
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
4
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
5
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
6
6
|
import { aProjectFlat } from '@antv/l7-utils';
|
|
7
7
|
import { vec2 } from 'gl-matrix';
|
|
8
8
|
var tmp = vec2.create(); // eslint-disable-next-line @typescript-eslint/no-unused-vars
|
package/es/utils/grid-index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
2
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
3
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
1
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
2
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
3
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
4
4
|
|
|
5
5
|
function _createForOfIteratorHelper(o, allowArrayLike) { var it = typeof Symbol !== "undefined" && o[Symbol.iterator] || o["@@iterator"]; if (!it) { if (Array.isArray(o) || (it = _unsupportedIterableToArray(o)) || allowArrayLike && o && typeof o.length === "number") { if (it) o = it; var i = 0; var F = function F() {}; return { s: F, n: function n() { if (i >= o.length) return { done: true }; return { done: false, value: o[i++] }; }, e: function e(_e) { throw _e; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var normalCompletion = true, didErr = false, err; return { s: function s() { it = it.call(o); }, n: function n() { var step = it.next(); normalCompletion = step.done; return step; }, e: function e(_e2) { didErr = true; err = _e2; }, f: function f() { try { if (!normalCompletion && it.return != null) it.return(); } finally { if (didErr) throw err; } } }; }
|
|
6
6
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
|
1
|
+
import _toConsumableArray from "@babel/runtime/helpers/esm/toConsumableArray";
|
|
2
2
|
import { aProjectFlat } from '@antv/l7-utils';
|
|
3
3
|
import { vec2 } from 'gl-matrix';
|
|
4
4
|
export function computeMiter(tangent, miter, lineA, lineB, halfThick) {
|
package/es/utils/simpleLine.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
2
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
3
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
1
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
2
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
3
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
4
4
|
import { aProjectFlat } from '@antv/l7-utils';
|
|
5
5
|
import { vec2 } from 'gl-matrix';
|
|
6
6
|
var lineA = vec2.create();
|
package/es/wind/index.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
2
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
3
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
4
|
-
import _assertThisInitialized from "@babel/runtime/helpers/assertThisInitialized";
|
|
5
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
6
|
-
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
7
|
-
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
8
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
1
|
+
import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
|
|
2
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
3
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
4
|
+
import _assertThisInitialized from "@babel/runtime/helpers/esm/assertThisInitialized";
|
|
5
|
+
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
6
|
+
import _possibleConstructorReturn from "@babel/runtime/helpers/esm/possibleConstructorReturn";
|
|
7
|
+
import _getPrototypeOf from "@babel/runtime/helpers/esm/getPrototypeOf";
|
|
8
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
9
9
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
10
10
|
|
|
11
11
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
package/es/wind/models/wind.js
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
2
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
3
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
4
|
-
import _assertThisInitialized from "@babel/runtime/helpers/assertThisInitialized";
|
|
5
|
-
import _inherits from "@babel/runtime/helpers/inherits";
|
|
6
|
-
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
7
|
-
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
8
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
1
|
+
import _asyncToGenerator from "@babel/runtime/helpers/esm/asyncToGenerator";
|
|
2
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
3
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
4
|
+
import _assertThisInitialized from "@babel/runtime/helpers/esm/assertThisInitialized";
|
|
5
|
+
import _inherits from "@babel/runtime/helpers/esm/inherits";
|
|
6
|
+
import _possibleConstructorReturn from "@babel/runtime/helpers/esm/possibleConstructorReturn";
|
|
7
|
+
import _getPrototypeOf from "@babel/runtime/helpers/esm/getPrototypeOf";
|
|
8
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
9
9
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
10
10
|
|
|
11
11
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
@@ -317,6 +317,8 @@ var WindModel = /*#__PURE__*/function (_BaseModel) {
|
|
|
317
317
|
var _ref3 = this.layer.getLayerConfig(),
|
|
318
318
|
opacity = _ref3.opacity;
|
|
319
319
|
|
|
320
|
+
this.layerService.beforeRenderData(this.layer);
|
|
321
|
+
this.layer.hooks.beforeRender.call();
|
|
320
322
|
this.layerService.renderMask(this.layer.masks);
|
|
321
323
|
(_this$colorModel = this.colorModel) === null || _this$colorModel === void 0 ? void 0 : _this$colorModel.draw({
|
|
322
324
|
uniforms: {
|
|
@@ -324,6 +326,7 @@ var WindModel = /*#__PURE__*/function (_BaseModel) {
|
|
|
324
326
|
u_texture: this.texture
|
|
325
327
|
}
|
|
326
328
|
});
|
|
329
|
+
this.layer.hooks.afterRender.call();
|
|
327
330
|
}
|
|
328
331
|
}]);
|
|
329
332
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
|
|
2
|
-
import _createClass from "@babel/runtime/helpers/createClass";
|
|
3
|
-
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
1
|
+
import _classCallCheck from "@babel/runtime/helpers/esm/classCallCheck";
|
|
2
|
+
import _createClass from "@babel/runtime/helpers/esm/createClass";
|
|
3
|
+
import _defineProperty from "@babel/runtime/helpers/esm/defineProperty";
|
|
4
4
|
import * as glUtils from "./utils";
|
|
5
5
|
import { drawFrag, drawVert, fullScreenFrag, fullScreenVert, updateFrag, updateVert } from "./windShader";
|
|
6
6
|
|
package/lib/core/BaseLayer.js
CHANGED
|
@@ -625,6 +625,8 @@ var BaseLayer = (_dec = (0, _l7Core.lazyInject)(_l7Core.TYPES.IGlobalConfigServi
|
|
|
625
625
|
return this;
|
|
626
626
|
}
|
|
627
627
|
|
|
628
|
+
this.layerService.beforeRenderData(this);
|
|
629
|
+
|
|
628
630
|
if (this.encodeDataLength <= 0 && !this.forceRender) {
|
|
629
631
|
return this;
|
|
630
632
|
} // Tip: this.getEncodedData().length !== 0 这个判断是为了解决在 2.5.x 引入数据纹理后产生的 空数据渲染导致 texture 超出上限问题
|
|
@@ -645,27 +647,19 @@ var BaseLayer = (_dec = (0, _l7Core.lazyInject)(_l7Core.TYPES.IGlobalConfigServi
|
|
|
645
647
|
while (1) {
|
|
646
648
|
switch (_context2.prev = _context2.next) {
|
|
647
649
|
case 0:
|
|
648
|
-
if (!(this.encodeDataLength <= 0 && !this.forceRender)) {
|
|
649
|
-
_context2.next = 2;
|
|
650
|
-
break;
|
|
651
|
-
}
|
|
652
|
-
|
|
653
|
-
return _context2.abrupt("return");
|
|
654
|
-
|
|
655
|
-
case 2:
|
|
656
650
|
if (!(this.multiPassRenderer && this.multiPassRenderer.getRenderFlag())) {
|
|
657
|
-
_context2.next =
|
|
651
|
+
_context2.next = 5;
|
|
658
652
|
break;
|
|
659
653
|
}
|
|
660
654
|
|
|
661
|
-
_context2.next =
|
|
655
|
+
_context2.next = 3;
|
|
662
656
|
return this.multiPassRenderer.render();
|
|
663
657
|
|
|
664
|
-
case
|
|
665
|
-
_context2.next =
|
|
658
|
+
case 3:
|
|
659
|
+
_context2.next = 6;
|
|
666
660
|
break;
|
|
667
661
|
|
|
668
|
-
case
|
|
662
|
+
case 5:
|
|
669
663
|
if (this.multiPassRenderer) {
|
|
670
664
|
// renderPass 触发的渲染
|
|
671
665
|
this.renderModels();
|
|
@@ -673,7 +667,7 @@ var BaseLayer = (_dec = (0, _l7Core.lazyInject)(_l7Core.TYPES.IGlobalConfigServi
|
|
|
673
667
|
this.renderModels();
|
|
674
668
|
}
|
|
675
669
|
|
|
676
|
-
case
|
|
670
|
+
case 6:
|
|
677
671
|
case "end":
|
|
678
672
|
return _context2.stop();
|
|
679
673
|
}
|
|
@@ -1067,7 +1061,9 @@ var BaseLayer = (_dec = (0, _l7Core.lazyInject)(_l7Core.TYPES.IGlobalConfigServi
|
|
|
1067
1061
|
} // this.layerSource.inited 为 true update 事件不会再触发
|
|
1068
1062
|
|
|
1069
1063
|
|
|
1070
|
-
this.layerSource.on('update', function () {
|
|
1064
|
+
this.layerSource.on('update', function (_ref3) {
|
|
1065
|
+
var type = _ref3.type;
|
|
1066
|
+
|
|
1071
1067
|
if (_this8.coordCenter === undefined) {
|
|
1072
1068
|
var _this8$mapService;
|
|
1073
1069
|
|
|
@@ -1079,7 +1075,10 @@ var BaseLayer = (_dec = (0, _l7Core.lazyInject)(_l7Core.TYPES.IGlobalConfigServi
|
|
|
1079
1075
|
}
|
|
1080
1076
|
}
|
|
1081
1077
|
|
|
1082
|
-
|
|
1078
|
+
if (type === 'update') {
|
|
1079
|
+
// source 初始化不需要处理
|
|
1080
|
+
_this8.sourceEvent();
|
|
1081
|
+
}
|
|
1083
1082
|
});
|
|
1084
1083
|
} // layer 初始化source
|
|
1085
1084
|
|
|
@@ -1193,9 +1192,9 @@ var BaseLayer = (_dec = (0, _l7Core.lazyInject)(_l7Core.TYPES.IGlobalConfigServi
|
|
|
1193
1192
|
}
|
|
1194
1193
|
}, {
|
|
1195
1194
|
key: "pick",
|
|
1196
|
-
value: function pick(
|
|
1197
|
-
var x =
|
|
1198
|
-
y =
|
|
1195
|
+
value: function pick(_ref7) {
|
|
1196
|
+
var x = _ref7.x,
|
|
1197
|
+
y = _ref7.y;
|
|
1199
1198
|
this.interactionService.triggerHover({
|
|
1200
1199
|
x: x,
|
|
1201
1200
|
y: y
|
|
@@ -1228,9 +1227,9 @@ var BaseLayer = (_dec = (0, _l7Core.lazyInject)(_l7Core.TYPES.IGlobalConfigServi
|
|
|
1228
1227
|
return _context3.abrupt("return", new Promise(function (resolve, reject) {
|
|
1229
1228
|
// filter supported worker & worker enabled layer
|
|
1230
1229
|
if (workerOptions && workerOptions.modelType in _l7Utils.WorkerSourceMap && workerEnabled) {
|
|
1231
|
-
_this10.styleAttributeService.createAttributesAndIndicesAscy(_this10.encodedData, segmentNumber, workerOptions).then(function (
|
|
1232
|
-
var attributes =
|
|
1233
|
-
elements =
|
|
1230
|
+
_this10.styleAttributeService.createAttributesAndIndicesAscy(_this10.encodedData, segmentNumber, workerOptions).then(function (_ref8) {
|
|
1231
|
+
var attributes = _ref8.attributes,
|
|
1232
|
+
elements = _ref8.elements;
|
|
1234
1233
|
var m = createModel((0, _objectSpread2.default)({
|
|
1235
1234
|
attributes: attributes,
|
|
1236
1235
|
uniforms: uniforms,
|
|
@@ -1423,17 +1422,8 @@ var BaseLayer = (_dec = (0, _l7Core.lazyInject)(_l7Core.TYPES.IGlobalConfigServi
|
|
|
1423
1422
|
// TODO: this.getEncodedData().length > 0 这个判断是为了解决在 2.5.x 引入数据纹理后产生的 空数据渲染导致 texture 超出上限问题
|
|
1424
1423
|
if (this.encodeDataLength <= 0 && !this.forceRender) {
|
|
1425
1424
|
return this;
|
|
1426
|
-
}
|
|
1427
|
-
// if (this.layerModelNeedUpdate && this.layerModel) {
|
|
1428
|
-
// this.layerModel.buildModels((models: IModel[]) => {
|
|
1429
|
-
// this.models = models;
|
|
1430
|
-
// this.hooks.beforeRender.call();
|
|
1431
|
-
// this.layerModelNeedUpdate = false;
|
|
1432
|
-
// });
|
|
1433
|
-
// }
|
|
1434
|
-
|
|
1425
|
+
}
|
|
1435
1426
|
|
|
1436
|
-
this.layerService.beforeRenderData(this);
|
|
1437
1427
|
this.hooks.beforeRender.call();
|
|
1438
1428
|
this.models.forEach(function (model) {
|
|
1439
1429
|
model.draw({
|
|
@@ -1454,7 +1444,8 @@ var BaseLayer = (_dec = (0, _l7Core.lazyInject)(_l7Core.TYPES.IGlobalConfigServi
|
|
|
1454
1444
|
}));
|
|
1455
1445
|
}
|
|
1456
1446
|
|
|
1457
|
-
if (!this.
|
|
1447
|
+
if (!this.startInit) {
|
|
1448
|
+
// 开始初始化执行
|
|
1458
1449
|
this.pendingStyleAttributes.push({
|
|
1459
1450
|
attributeName: type,
|
|
1460
1451
|
attributeField: field,
|