@vcmap/core 6.0.7 → 6.1.0-rc.2
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/dist/cesium.d.ts +3 -0
- package/dist/index.d.ts +16 -1
- package/dist/index.js +16 -1
- package/dist/index.js.map +1 -1
- package/dist/ol.d.ts +8 -1
- package/dist/src/featureProvider/featureProviderSymbols.d.ts +5 -0
- package/dist/src/featureProvider/featureProviderSymbols.js +5 -1
- package/dist/src/featureProvider/featureProviderSymbols.js.map +1 -1
- package/dist/src/interaction/featureAtPixelInteraction.js +58 -62
- package/dist/src/interaction/featureAtPixelInteraction.js.map +1 -1
- package/dist/src/interaction/featureProviderInteraction.js +25 -13
- package/dist/src/interaction/featureProviderInteraction.js.map +1 -1
- package/dist/src/layer/cesium/sourceVectorContextSync.d.ts +27 -0
- package/dist/src/layer/cesium/sourceVectorContextSync.js +94 -0
- package/dist/src/layer/cesium/sourceVectorContextSync.js.map +1 -0
- package/dist/src/layer/cesium/vectorCesiumImpl.d.ts +4 -27
- package/dist/src/layer/cesium/vectorCesiumImpl.js +15 -107
- package/dist/src/layer/cesium/vectorCesiumImpl.js.map +1 -1
- package/dist/src/layer/cesium/vectorContext.d.ts +12 -1
- package/dist/src/layer/cesium/vectorContext.js +6 -0
- package/dist/src/layer/cesium/vectorContext.js.map +1 -1
- package/dist/src/layer/layerSymbols.js +1 -1
- package/dist/src/layer/layerSymbols.js.map +1 -1
- package/dist/src/layer/oblique/sourceObliqueSync.d.ts +18 -0
- package/dist/src/layer/oblique/sourceObliqueSync.js +319 -0
- package/dist/src/layer/oblique/sourceObliqueSync.js.map +1 -0
- package/dist/src/layer/oblique/vectorObliqueImpl.d.ts +2 -40
- package/dist/src/layer/oblique/vectorObliqueImpl.js +8 -283
- package/dist/src/layer/oblique/vectorObliqueImpl.js.map +1 -1
- package/dist/src/layer/vectorLayer.d.ts +10 -1
- package/dist/src/layer/vectorLayer.js +23 -1
- package/dist/src/layer/vectorLayer.js.map +1 -1
- package/dist/src/map/baseOLMap.js +8 -1
- package/dist/src/map/baseOLMap.js.map +1 -1
- package/dist/src/map/cesiumMap.d.ts +2 -0
- package/dist/src/map/cesiumMap.js +26 -1
- package/dist/src/map/cesiumMap.js.map +1 -1
- package/dist/src/map/vcsMap.d.ts +24 -12
- package/dist/src/map/vcsMap.js +92 -38
- package/dist/src/map/vcsMap.js.map +1 -1
- package/dist/src/ol/source/ClusterEnhancedVectorSource.d.ts +6 -4
- package/dist/src/ol/source/ClusterEnhancedVectorSource.js +4 -9
- package/dist/src/ol/source/ClusterEnhancedVectorSource.js.map +1 -1
- package/dist/src/ol/source/VcsCluster.d.ts +10 -10
- package/dist/src/ol/source/VcsCluster.js +23 -7
- package/dist/src/ol/source/VcsCluster.js.map +1 -1
- package/dist/src/util/clipping/clippingPolygonHelper.d.ts +7 -0
- package/dist/src/util/clipping/clippingPolygonHelper.js +53 -0
- package/dist/src/util/clipping/clippingPolygonHelper.js.map +1 -0
- package/dist/src/util/clipping/clippingPolygonObject.d.ts +59 -0
- package/dist/src/util/clipping/clippingPolygonObject.js +158 -0
- package/dist/src/util/clipping/clippingPolygonObject.js.map +1 -0
- package/dist/src/util/clipping/clippingPolygonObjectCollection.d.ts +18 -0
- package/dist/src/util/clipping/clippingPolygonObjectCollection.js +167 -0
- package/dist/src/util/clipping/clippingPolygonObjectCollection.js.map +1 -0
- package/dist/src/util/layerCollection.d.ts +11 -1
- package/dist/src/util/layerCollection.js +67 -12
- package/dist/src/util/layerCollection.js.map +1 -1
- package/dist/src/util/mapCollection.d.ts +16 -1
- package/dist/src/util/mapCollection.js +37 -3
- package/dist/src/util/mapCollection.js.map +1 -1
- package/dist/src/util/renderScreenshot.d.ts +9 -0
- package/dist/src/util/renderScreenshot.js +162 -0
- package/dist/src/util/renderScreenshot.js.map +1 -0
- package/dist/src/util/rotation.d.ts +30 -0
- package/dist/src/util/rotation.js +145 -0
- package/dist/src/util/rotation.js.map +1 -0
- package/dist/src/util/vcsTemplate.d.ts +7 -0
- package/dist/src/util/vcsTemplate.js +248 -0
- package/dist/src/util/vcsTemplate.js.map +1 -0
- package/dist/src/vcsApp.d.ts +7 -0
- package/dist/src/vcsApp.js +29 -0
- package/dist/src/vcsApp.js.map +1 -1
- package/dist/src/vcsModule.d.ts +6 -2
- package/dist/src/vcsModule.js.map +1 -1
- package/dist/src/vectorCluster/vectorClusterCesiumContext.d.ts +18 -0
- package/dist/src/{layer/cesium/clusterContext.js → vectorCluster/vectorClusterCesiumContext.js} +28 -42
- package/dist/src/vectorCluster/vectorClusterCesiumContext.js.map +1 -0
- package/dist/src/vectorCluster/vectorClusterGroup.d.ts +96 -0
- package/dist/src/vectorCluster/vectorClusterGroup.js +320 -0
- package/dist/src/vectorCluster/vectorClusterGroup.js.map +1 -0
- package/dist/src/vectorCluster/vectorClusterGroupCesiumImpl.d.ts +20 -0
- package/dist/src/vectorCluster/vectorClusterGroupCesiumImpl.js +115 -0
- package/dist/src/vectorCluster/vectorClusterGroupCesiumImpl.js.map +1 -0
- package/dist/src/vectorCluster/vectorClusterGroupCollection.d.ts +19 -0
- package/dist/src/vectorCluster/vectorClusterGroupCollection.js +37 -0
- package/dist/src/vectorCluster/vectorClusterGroupCollection.js.map +1 -0
- package/dist/src/vectorCluster/vectorClusterGroupImpl.d.ts +31 -0
- package/dist/src/vectorCluster/vectorClusterGroupImpl.js +76 -0
- package/dist/src/vectorCluster/vectorClusterGroupImpl.js.map +1 -0
- package/dist/src/vectorCluster/vectorClusterGroupObliqueImpl.d.ts +17 -0
- package/dist/src/vectorCluster/vectorClusterGroupObliqueImpl.js +62 -0
- package/dist/src/vectorCluster/vectorClusterGroupObliqueImpl.js.map +1 -0
- package/dist/src/vectorCluster/vectorClusterGroupOpenlayersImpl.d.ts +17 -0
- package/dist/src/vectorCluster/vectorClusterGroupOpenlayersImpl.js +62 -0
- package/dist/src/vectorCluster/vectorClusterGroupOpenlayersImpl.js.map +1 -0
- package/dist/src/vectorCluster/vectorClusterStyleItem.d.ts +110 -0
- package/dist/src/vectorCluster/vectorClusterStyleItem.js +374 -0
- package/dist/src/vectorCluster/vectorClusterStyleItem.js.map +1 -0
- package/dist/src/vectorCluster/vectorClusterSymbols.d.ts +1 -0
- package/dist/src/vectorCluster/vectorClusterSymbols.js +3 -0
- package/dist/src/vectorCluster/vectorClusterSymbols.js.map +1 -0
- package/index.ts +42 -1
- package/package.json +3 -1
- package/src/cesium/cesium.d.ts +3 -0
- package/src/featureProvider/featureProviderSymbols.ts +6 -1
- package/src/interaction/featureAtPixelInteraction.ts +109 -84
- package/src/interaction/featureProviderInteraction.ts +42 -28
- package/src/layer/cesium/sourceVectorContextSync.ts +134 -0
- package/src/layer/cesium/vcsTile/vcsDebugTile.ts +1 -1
- package/src/layer/cesium/vcsTile/vcsVectorTile.ts +1 -1
- package/src/layer/cesium/vectorCesiumImpl.ts +30 -144
- package/src/layer/cesium/vectorContext.ts +17 -1
- package/src/layer/layerSymbols.ts +1 -1
- package/src/layer/oblique/sourceObliqueSync.ts +436 -0
- package/src/layer/oblique/vectorObliqueImpl.ts +11 -397
- package/src/layer/vectorLayer.ts +35 -2
- package/src/map/baseOLMap.ts +8 -1
- package/src/map/cesiumMap.ts +36 -3
- package/src/map/vcsMap.ts +121 -47
- package/src/ol/ol.d.ts +8 -1
- package/src/ol/source/{ClusterEnhancedVectorSource.js → ClusterEnhancedVectorSource.ts} +7 -10
- package/src/ol/source/VcsCluster.ts +58 -0
- package/src/util/clipping/clippingPolygonHelper.ts +86 -0
- package/src/util/clipping/clippingPolygonObject.ts +223 -0
- package/src/util/clipping/clippingPolygonObjectCollection.ts +249 -0
- package/src/util/layerCollection.ts +90 -12
- package/src/util/mapCollection.ts +53 -2
- package/src/util/renderScreenshot.ts +193 -0
- package/src/util/rotation.ts +215 -0
- package/src/util/vcsTemplate.ts +373 -0
- package/src/vcsApp.ts +65 -0
- package/src/vcsModule.ts +6 -2
- package/src/vectorCluster/vectorClusterCesiumContext.ts +123 -0
- package/src/vectorCluster/vectorClusterGroup.ts +463 -0
- package/src/vectorCluster/vectorClusterGroupCesiumImpl.ts +176 -0
- package/src/vectorCluster/vectorClusterGroupCollection.ts +43 -0
- package/src/vectorCluster/vectorClusterGroupImpl.ts +107 -0
- package/src/vectorCluster/vectorClusterGroupObliqueImpl.ts +84 -0
- package/src/vectorCluster/vectorClusterGroupOpenlayersImpl.ts +81 -0
- package/src/vectorCluster/vectorClusterStyleItem.ts +490 -0
- package/src/vectorCluster/vectorClusterSymbols.ts +2 -0
- package/dist/src/layer/cesium/clusterContext.d.ts +0 -20
- package/dist/src/layer/cesium/clusterContext.js.map +0 -1
- package/src/layer/cesium/clusterContext.ts +0 -140
- package/src/ol/source/VcsCluster.js +0 -37
|
@@ -0,0 +1,94 @@
|
|
|
1
|
+
import { getLogger } from '@vcsuite/logger';
|
|
2
|
+
import { unByKey } from 'ol/Observable.js';
|
|
3
|
+
/**
|
|
4
|
+
* Creates a SourceVectorContextSync. This ensures that the features in the source are synced to the context.
|
|
5
|
+
* Adding, removing and changing features in the source will be reflected in the context.
|
|
6
|
+
* @param source
|
|
7
|
+
* @param context
|
|
8
|
+
* @param scene
|
|
9
|
+
* @param style
|
|
10
|
+
* @param vectorProperties - the vector properties or a function returning vector properties for a feature
|
|
11
|
+
*/
|
|
12
|
+
export function createSourceVectorContextSync(source, context, scene, style, vectorProperties) {
|
|
13
|
+
const featureToAdd = new Set();
|
|
14
|
+
let active = false;
|
|
15
|
+
const vectorPropertiesChanged = new Map();
|
|
16
|
+
const getVectorProperties = typeof vectorProperties === 'function'
|
|
17
|
+
? vectorProperties
|
|
18
|
+
: () => vectorProperties;
|
|
19
|
+
let refresh;
|
|
20
|
+
const addFeature = async (feature) => {
|
|
21
|
+
const featureVectorProperties = getVectorProperties(feature);
|
|
22
|
+
if (!vectorPropertiesChanged.has(featureVectorProperties)) {
|
|
23
|
+
vectorPropertiesChanged.set(featureVectorProperties, featureVectorProperties.propertyChanged.addEventListener(refresh));
|
|
24
|
+
}
|
|
25
|
+
if (active) {
|
|
26
|
+
// XXX cluster check here? or on init?
|
|
27
|
+
await context.addFeature(feature, style, featureVectorProperties, scene);
|
|
28
|
+
}
|
|
29
|
+
else {
|
|
30
|
+
featureToAdd.add(feature);
|
|
31
|
+
}
|
|
32
|
+
};
|
|
33
|
+
const removeFeature = (feature) => {
|
|
34
|
+
context.removeFeature(feature);
|
|
35
|
+
featureToAdd.delete(feature);
|
|
36
|
+
};
|
|
37
|
+
const featureChanged = async (feature) => {
|
|
38
|
+
featureToAdd.delete(feature);
|
|
39
|
+
await addFeature(feature);
|
|
40
|
+
};
|
|
41
|
+
const addFeatures = (features) => {
|
|
42
|
+
// TODO we should make this non-blocking to better handle larger data sets check in RIWA Impl
|
|
43
|
+
features.forEach((f) => {
|
|
44
|
+
addFeature(f).catch((err) => {
|
|
45
|
+
getLogger('SourceVectorContextSync').error('failed to convert feature', f, err);
|
|
46
|
+
});
|
|
47
|
+
});
|
|
48
|
+
};
|
|
49
|
+
const addCachedFeatures = () => {
|
|
50
|
+
addFeatures([...featureToAdd]);
|
|
51
|
+
featureToAdd.clear();
|
|
52
|
+
};
|
|
53
|
+
refresh = () => {
|
|
54
|
+
context.clear();
|
|
55
|
+
addFeatures(source.getFeatures());
|
|
56
|
+
};
|
|
57
|
+
const olListeners = [
|
|
58
|
+
source.on('addfeature', (event) => {
|
|
59
|
+
addFeature(event.feature).catch(() => {
|
|
60
|
+
getLogger().error('failed to convert feature');
|
|
61
|
+
});
|
|
62
|
+
}),
|
|
63
|
+
source.on('removefeature', (event) => {
|
|
64
|
+
removeFeature(event.feature);
|
|
65
|
+
}),
|
|
66
|
+
source.on('changefeature', (event) => {
|
|
67
|
+
featureChanged(event.feature).catch((_e) => {
|
|
68
|
+
getLogger().error('failed to convert feature');
|
|
69
|
+
});
|
|
70
|
+
}),
|
|
71
|
+
];
|
|
72
|
+
addFeatures(source.getFeatures());
|
|
73
|
+
return {
|
|
74
|
+
get active() {
|
|
75
|
+
return active;
|
|
76
|
+
},
|
|
77
|
+
activate() {
|
|
78
|
+
active = true;
|
|
79
|
+
addCachedFeatures();
|
|
80
|
+
},
|
|
81
|
+
deactivate() {
|
|
82
|
+
active = false;
|
|
83
|
+
},
|
|
84
|
+
refresh,
|
|
85
|
+
destroy() {
|
|
86
|
+
unByKey(olListeners);
|
|
87
|
+
vectorPropertiesChanged.forEach((removeListener) => {
|
|
88
|
+
removeListener();
|
|
89
|
+
});
|
|
90
|
+
vectorPropertiesChanged.clear();
|
|
91
|
+
},
|
|
92
|
+
};
|
|
93
|
+
}
|
|
94
|
+
//# sourceMappingURL=sourceVectorContextSync.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sourceVectorContextSync.js","sourceRoot":"","sources":["../../../../src/layer/cesium/sourceVectorContextSync.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,OAAO,EAAE,MAAM,kBAAkB,CAAC;AAoB3C;;;;;;;;GAQG;AACH,MAAM,UAAU,6BAA6B,CAC3C,MAAoB,EACpB,OAAmD,EACnD,KAAY,EACZ,KAAgB,EAChB,gBAAuE;IAEvE,MAAM,YAAY,GAAG,IAAI,GAAG,EAAW,CAAC;IACxC,IAAI,MAAM,GAAG,KAAK,CAAC;IACnB,MAAM,uBAAuB,GAAG,IAAI,GAAG,EAAgC,CAAC;IACxE,MAAM,mBAAmB,GACvB,OAAO,gBAAgB,KAAK,UAAU;QACpC,CAAC,CAAC,gBAAgB;QAClB,CAAC,CAAC,GAAqB,EAAE,CAAC,gBAAgB,CAAC;IAE/C,IAAI,OAAmB,CAAC;IACxB,MAAM,UAAU,GAAG,KAAK,EAAE,OAAgB,EAAiB,EAAE;QAC3D,MAAM,uBAAuB,GAAG,mBAAmB,CAAC,OAAO,CAAC,CAAC;QAC7D,IAAI,CAAC,uBAAuB,CAAC,GAAG,CAAC,uBAAuB,CAAC,EAAE,CAA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CAAC;AACJ,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { type SplitDirection } from '@vcmap-cesium/engine';
|
|
2
2
|
import type VectorSource from 'ol/source/Vector.js';
|
|
3
3
|
import LayerImplementation from '../layerImplementation.js';
|
|
4
4
|
import type CesiumMap from '../../map/cesiumMap.js';
|
|
@@ -8,7 +8,6 @@ import type VectorProperties from '../vectorProperties.js';
|
|
|
8
8
|
import type StyleItem from '../../style/styleItem.js';
|
|
9
9
|
import type FeatureVisibility from '../featureVisibility.js';
|
|
10
10
|
import type GlobalHider from '../globalHider.js';
|
|
11
|
-
import VectorContext from './vectorContext.js';
|
|
12
11
|
/**
|
|
13
12
|
* represents a specific vector layer for cesium.
|
|
14
13
|
*/
|
|
@@ -20,42 +19,20 @@ declare class VectorCesiumImpl extends LayerImplementation<CesiumMap> implements
|
|
|
20
19
|
style: StyleItem;
|
|
21
20
|
featureVisibility: FeatureVisibility;
|
|
22
21
|
private _featureVisibilityListeners;
|
|
23
|
-
private
|
|
24
|
-
|
|
25
|
-
private
|
|
26
|
-
/**
|
|
27
|
-
* A set of ol.Features to add once the map is back to cesium
|
|
28
|
-
*/
|
|
29
|
-
private _featureToAdd;
|
|
30
|
-
protected _context: VectorContext | null;
|
|
31
|
-
private _scene;
|
|
22
|
+
private _rootCollection;
|
|
23
|
+
private _context;
|
|
24
|
+
private _sourceVectorContextSync;
|
|
32
25
|
globalHider: GlobalHider | undefined;
|
|
33
26
|
constructor(map: CesiumMap, options: VectorImplementationOptions);
|
|
34
|
-
private _addListeners;
|
|
35
|
-
protected _setupContext(cesiumMap: CesiumMap): Promise<void>;
|
|
36
27
|
initialize(): Promise<void>;
|
|
37
|
-
private _addFeatures;
|
|
38
|
-
/**
|
|
39
|
-
* converts a feature and adds the associated primitives to the collection of primitives
|
|
40
|
-
*/
|
|
41
|
-
private _addFeature;
|
|
42
28
|
/**
|
|
43
29
|
* Forces a complete re-render of all features.
|
|
44
30
|
*/
|
|
45
31
|
refresh(): void;
|
|
46
|
-
/**
|
|
47
|
-
* removes the primitive of the specified feature
|
|
48
|
-
*/
|
|
49
|
-
private _removeFeature;
|
|
50
|
-
/**
|
|
51
|
-
* called when a features property have changed
|
|
52
|
-
*/
|
|
53
|
-
private _featureChanged;
|
|
54
32
|
activate(): Promise<void>;
|
|
55
33
|
deactivate(): void;
|
|
56
34
|
updateStyle(style: StyleItem, silent?: boolean): void;
|
|
57
35
|
updateSplitDirection(splitDirection: SplitDirection): void;
|
|
58
|
-
protected _destroyCollection(): void;
|
|
59
36
|
destroy(): void;
|
|
60
37
|
}
|
|
61
38
|
export default VectorCesiumImpl;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { PrimitiveCollection, } from '@vcmap-cesium/engine';
|
|
1
|
+
import { PrimitiveCollection } from '@vcmap-cesium/engine';
|
|
3
2
|
import { vcsLayerName } from '../layerSymbols.js';
|
|
4
3
|
import LayerImplementation from '../layerImplementation.js';
|
|
5
4
|
import { synchronizeFeatureVisibilityWithSource } from '../vectorHelpers.js';
|
|
6
5
|
import VectorContext from './vectorContext.js';
|
|
6
|
+
import { createSourceVectorContextSync, } from './sourceVectorContextSync.js';
|
|
7
7
|
/**
|
|
8
8
|
* represents a specific vector layer for cesium.
|
|
9
9
|
*/
|
|
@@ -17,16 +17,9 @@ class VectorCesiumImpl extends LayerImplementation {
|
|
|
17
17
|
style;
|
|
18
18
|
featureVisibility;
|
|
19
19
|
_featureVisibilityListeners = [];
|
|
20
|
-
// eslint-disable-next-line class-methods-use-this
|
|
21
|
-
_removeVectorPropertiesChangeHandler = () => { };
|
|
22
20
|
_rootCollection;
|
|
23
|
-
_olListeners = [];
|
|
24
|
-
/**
|
|
25
|
-
* A set of ol.Features to add once the map is back to cesium
|
|
26
|
-
*/
|
|
27
|
-
_featureToAdd = new Set();
|
|
28
21
|
_context = null;
|
|
29
|
-
|
|
22
|
+
_sourceVectorContextSync;
|
|
30
23
|
globalHider;
|
|
31
24
|
constructor(map, options) {
|
|
32
25
|
super(map, options);
|
|
@@ -39,88 +32,28 @@ class VectorCesiumImpl extends LayerImplementation {
|
|
|
39
32
|
this._rootCollection[vcsLayerName] = options.name;
|
|
40
33
|
this.globalHider = options.globalHider;
|
|
41
34
|
}
|
|
42
|
-
_addListeners() {
|
|
43
|
-
this._olListeners.push(this.source.on('addfeature', (event) => {
|
|
44
|
-
this._addFeature(event.feature).catch(() => {
|
|
45
|
-
this.getLogger().error('failed to convert feature');
|
|
46
|
-
});
|
|
47
|
-
}));
|
|
48
|
-
this._olListeners.push(this.source.on('removefeature', (event) => {
|
|
49
|
-
this._removeFeature(event.feature);
|
|
50
|
-
}));
|
|
51
|
-
this._olListeners.push(this.source.on('changefeature', (event) => {
|
|
52
|
-
this._featureChanged(event.feature).catch((_e) => {
|
|
53
|
-
this.getLogger().error('failed to convert feature');
|
|
54
|
-
});
|
|
55
|
-
}));
|
|
56
|
-
this._removeVectorPropertiesChangeHandler =
|
|
57
|
-
this.vectorProperties.propertyChanged.addEventListener(this.refresh.bind(this));
|
|
58
|
-
}
|
|
59
|
-
_setupContext(cesiumMap) {
|
|
60
|
-
const rootCollection = this._rootCollection;
|
|
61
|
-
this._context = new VectorContext(cesiumMap, rootCollection, this.splitDirection);
|
|
62
|
-
cesiumMap.addPrimitiveCollection(rootCollection);
|
|
63
|
-
return Promise.resolve();
|
|
64
|
-
}
|
|
65
35
|
async initialize() {
|
|
66
36
|
if (!this.initialized) {
|
|
67
|
-
this.
|
|
68
|
-
this.
|
|
69
|
-
this.
|
|
70
|
-
await this._setupContext(this.map);
|
|
37
|
+
this._context = new VectorContext(this.map, this._rootCollection, this.splitDirection);
|
|
38
|
+
this.map.addPrimitiveCollection(this._rootCollection);
|
|
39
|
+
this._sourceVectorContextSync = createSourceVectorContextSync(this.source, this._context, this.map.getScene(), this.style.style, this.vectorProperties);
|
|
71
40
|
}
|
|
72
41
|
await super.initialize();
|
|
73
42
|
if (this.splitDirection) {
|
|
74
43
|
this.updateSplitDirection(this.splitDirection);
|
|
75
44
|
}
|
|
76
45
|
}
|
|
77
|
-
_addFeatures(features) {
|
|
78
|
-
// TODO we should make this non-blocking to better handle larger data sets check in RIWA Impl
|
|
79
|
-
features.forEach((f) => {
|
|
80
|
-
this._addFeature(f).catch((err) => {
|
|
81
|
-
this.getLogger().error('failed to convert feature', f, err);
|
|
82
|
-
});
|
|
83
|
-
});
|
|
84
|
-
}
|
|
85
|
-
/**
|
|
86
|
-
* converts a feature and adds the associated primitives to the collection of primitives
|
|
87
|
-
*/
|
|
88
|
-
async _addFeature(feature) {
|
|
89
|
-
if (this.active) {
|
|
90
|
-
// XXX cluster check here? or on init?
|
|
91
|
-
await this._context.addFeature(feature, this.style.style, this.vectorProperties, this._scene);
|
|
92
|
-
}
|
|
93
|
-
else {
|
|
94
|
-
this._featureToAdd.add(feature);
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
46
|
/**
|
|
98
47
|
* Forces a complete re-render of all features.
|
|
99
48
|
*/
|
|
100
49
|
refresh() {
|
|
101
|
-
this.
|
|
102
|
-
this._addFeatures(this.source.getFeatures());
|
|
103
|
-
}
|
|
104
|
-
/**
|
|
105
|
-
* removes the primitive of the specified feature
|
|
106
|
-
*/
|
|
107
|
-
_removeFeature(feature) {
|
|
108
|
-
this._context?.removeFeature(feature);
|
|
109
|
-
this._featureToAdd.delete(feature);
|
|
110
|
-
}
|
|
111
|
-
/**
|
|
112
|
-
* called when a features property have changed
|
|
113
|
-
*/
|
|
114
|
-
async _featureChanged(feature) {
|
|
115
|
-
this._featureToAdd.delete(feature);
|
|
116
|
-
await this._addFeature(feature);
|
|
50
|
+
this._sourceVectorContextSync?.refresh();
|
|
117
51
|
}
|
|
118
52
|
async activate() {
|
|
119
53
|
if (!this.active) {
|
|
120
54
|
await super.activate();
|
|
121
55
|
if (this.active) {
|
|
122
|
-
this.
|
|
123
|
-
this._featureToAdd.clear();
|
|
56
|
+
this._sourceVectorContextSync?.activate();
|
|
124
57
|
this._rootCollection.show = true;
|
|
125
58
|
if (this._featureVisibilityListeners.length === 0) {
|
|
126
59
|
this._featureVisibilityListeners =
|
|
@@ -131,6 +64,7 @@ class VectorCesiumImpl extends LayerImplementation {
|
|
|
131
64
|
}
|
|
132
65
|
deactivate() {
|
|
133
66
|
super.deactivate();
|
|
67
|
+
this._sourceVectorContextSync?.deactivate();
|
|
134
68
|
this._rootCollection.show = false;
|
|
135
69
|
this._featureVisibilityListeners.forEach((cb) => {
|
|
136
70
|
cb();
|
|
@@ -140,11 +74,10 @@ class VectorCesiumImpl extends LayerImplementation {
|
|
|
140
74
|
updateStyle(style, silent) {
|
|
141
75
|
this.style = style;
|
|
142
76
|
if (this.initialized && !silent) {
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
});
|
|
77
|
+
this.source
|
|
78
|
+
.getFeatures()
|
|
79
|
+
.filter((f) => !f.getStyle())
|
|
80
|
+
.forEach((f) => f.changed());
|
|
148
81
|
}
|
|
149
82
|
}
|
|
150
83
|
updateSplitDirection(splitDirection) {
|
|
@@ -153,42 +86,17 @@ class VectorCesiumImpl extends LayerImplementation {
|
|
|
153
86
|
this._context?.updateSplitDirection(splitDirection);
|
|
154
87
|
}
|
|
155
88
|
}
|
|
156
|
-
_destroyCollection() {
|
|
157
|
-
this.map.removePrimitiveCollection(this._rootCollection);
|
|
158
|
-
}
|
|
159
89
|
destroy() {
|
|
160
90
|
if (this.initialized) {
|
|
91
|
+
this._sourceVectorContextSync?.destroy();
|
|
161
92
|
this._context?.destroy();
|
|
162
|
-
this.
|
|
93
|
+
this.map.removePrimitiveCollection(this._rootCollection);
|
|
163
94
|
}
|
|
164
95
|
this._context = null;
|
|
165
|
-
this._scene = undefined;
|
|
166
|
-
this._removeVectorPropertiesChangeHandler();
|
|
167
|
-
this._olListeners.forEach((listener) => {
|
|
168
|
-
unByKey(listener);
|
|
169
|
-
});
|
|
170
|
-
this._olListeners = [];
|
|
171
|
-
this._featureToAdd.clear();
|
|
172
96
|
this._featureVisibilityListeners.forEach((cb) => {
|
|
173
97
|
cb();
|
|
174
98
|
});
|
|
175
99
|
this._featureVisibilityListeners = [];
|
|
176
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
177
|
-
// @ts-ignore
|
|
178
|
-
this.source = null;
|
|
179
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
180
|
-
// @ts-ignore
|
|
181
|
-
this.vectorProperties = null;
|
|
182
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
183
|
-
// @ts-ignore
|
|
184
|
-
this.featureVisibility = null;
|
|
185
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
186
|
-
// @ts-ignore
|
|
187
|
-
this.style = null;
|
|
188
|
-
this.globalHider = undefined;
|
|
189
|
-
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
|
|
190
|
-
// @ts-ignore
|
|
191
|
-
this._rootCollection = null;
|
|
192
100
|
super.destroy();
|
|
193
101
|
}
|
|
194
102
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vectorCesiumImpl.js","sourceRoot":"","sources":["../../../../src/layer/cesium/vectorCesiumImpl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"vectorCesiumImpl.js","sourceRoot":"","sources":["../../../../src/layer/cesium/vectorCesiumImpl.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,mBAAmB,EAAuB,MAAM,sBAAsB,CAAC;AAEhF,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAClD,OAAO,mBAAmB,MAAM,2BAA2B,CAAC;AAC5D,OAAO,EAAE,sCAAsC,EAAE,MAAM,qBAAqB,CAAC;AAQ7E,OAAO,aAAa,MAAM,oBAAoB,CAAC;AAC/C,OAAO,EACL,6BAA6B,GAE9B,MAAM,8BAA8B,CAAC;AAEtC;;GAEG;AACH,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AC;IAED,WAAW,CAAC,KAAgB,EAAE,MAAgB;QAC5C,IAAI,CAAC,KAAK,GAAG,KAAK,CAAC;QACnB,IAAI,IAAI,CAAC,WAAW,IAAI,CAAC,MAAM,EAAE,CAAC;YAChC,IAAI,CAAC,MAAM;iBACR,WAAW,EAAE;iBACb,MAAM,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC;iBAC5B,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC,CAAC;QACjC,CAAC;IACH,CAAC;IAED,oBAAoB,CAAC,cAA8B;QACjD,IAAI,CAAC,cAAc,GAAG,cAAc,CAAC;QACrC,IAAI,IAAI,CAAC,WAAW,EAAE,CAAC;YACrB,IAAI,CAAC,QAAQ,EAAE,oBAAoB,CAAC,cAAc,CAAC,CAAC;QACtD,CAAC;IACH,CAAC;IAED,OAAO;QACL,IAAI,IAAI,CAAC,WAAW,EAAE,CAAC;YACrB,IAAI,CAAC,wBAAwB,EAAE,OAAO,EAAE,CAAC;YACzC,IAAI,CAAC,QAAQ,EAAE,OAAO,EAAE,CAAC;YACzB,IAAI,CAAC,GAAG,CAAC,yBAAyB,CAAC,IAAI,CAAC,eAAe,CAAC,CAAC;QAC3D,CAAC;QACD,IAAI,CAAC,QAAQ,GAAG,IAAI,CAAC;QACrB,IAAI,CAAC,2BAA2B,CAAC,OAAO,CAAC,CAAC,EAAE,EAAE,EAAE;YAC9C,EAAE,EAAE,CAAC;QACP,CAAC,CAAC,CAAC;QACH,IAAI,CAAC,2BAA2B,GAAG,EAAE,CAAC;QACtC,KAAK,CAAC,OAAO,EAAE,CAAC;IAClB,CAAC;CACF;AAED,eAAe,gBAAgB,CAAC"}
|
|
@@ -17,12 +17,22 @@ export declare const scaleSymbol: unique symbol;
|
|
|
17
17
|
export declare function setupScalingPrimitiveCollection(map: CesiumMap, primitiveCollection: PrimitiveCollection, dirtyRef: {
|
|
18
18
|
value: boolean;
|
|
19
19
|
}): () => void;
|
|
20
|
+
/**
|
|
21
|
+
* The context for vector rendering in cesium.
|
|
22
|
+
* Creates 1 to N primitives / models / billboards / labels for each feature
|
|
23
|
+
* added to the context depending on its style & vector properties.
|
|
24
|
+
* Uses the feature converters convert function under the hood to create the primitives.
|
|
25
|
+
*/
|
|
20
26
|
export interface CesiumVectorContext {
|
|
21
27
|
addFeature(feature: Feature, style: StyleLike, vectorProperties: VectorProperties, scene: Scene): Promise<void>;
|
|
28
|
+
hasFeature(feature: Feature): boolean;
|
|
22
29
|
removeFeature(feature: Feature): void;
|
|
23
|
-
updateSplitDirection(splitDirection: SplitDirection): void;
|
|
24
30
|
clear(): void;
|
|
31
|
+
destroy(): void;
|
|
25
32
|
}
|
|
33
|
+
/**
|
|
34
|
+
* The generic implementation of the vector context for Cesium
|
|
35
|
+
*/
|
|
26
36
|
export default class VectorContext implements CesiumVectorContext {
|
|
27
37
|
primitives: PrimitiveCollection;
|
|
28
38
|
scaledPrimitives: PrimitiveCollection;
|
|
@@ -37,6 +47,7 @@ export default class VectorContext implements CesiumVectorContext {
|
|
|
37
47
|
constructor(map: CesiumMap, rootCollection: PrimitiveCollection, splitDirection: SplitDirection);
|
|
38
48
|
private _addConvertedItems;
|
|
39
49
|
addFeature(feature: Feature, style: StyleLike, vectorProperties: VectorProperties, scene: Scene): Promise<void>;
|
|
50
|
+
hasFeature(feature: Feature): boolean;
|
|
40
51
|
removeFeature(feature: Feature): void;
|
|
41
52
|
updateSplitDirection(splitDirection: SplitDirection): void;
|
|
42
53
|
clear(): void;
|
|
@@ -70,6 +70,9 @@ export function setupScalingPrimitiveCollection(map, primitiveCollection, dirtyR
|
|
|
70
70
|
cachedVP = vp;
|
|
71
71
|
});
|
|
72
72
|
}
|
|
73
|
+
/**
|
|
74
|
+
* The generic implementation of the vector context for Cesium
|
|
75
|
+
*/
|
|
73
76
|
export default class VectorContext {
|
|
74
77
|
primitives = new PrimitiveCollection();
|
|
75
78
|
scaledPrimitives = new PrimitiveCollection();
|
|
@@ -216,6 +219,9 @@ export default class VectorContext {
|
|
|
216
219
|
this._addConvertedItems(feature, vectorProperties.getAllowPicking(feature), convertedItems, convertedIndices);
|
|
217
220
|
}
|
|
218
221
|
}
|
|
222
|
+
hasFeature(feature) {
|
|
223
|
+
return (this._featureItems.has(feature) || this._convertingFeatures.has(feature));
|
|
224
|
+
}
|
|
219
225
|
removeFeature(feature) {
|
|
220
226
|
this._convertingFeatures.get(feature)?.(false);
|
|
221
227
|
this._convertingFeatures.delete(feature);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"vectorContext.js","sourceRoot":"","sources":["../../../../src/layer/cesium/vectorContext.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,SAAS,EACT,mBAAmB,EACnB,UAAU,EAGV,eAAe,EACf,IAAI,IAAI,UAAU,EAClB,OAAO,EACP,KAAK,EAEL,mBAAmB,GAGpB,MAAM,sBAAsB,CAAC;AAI9B,OAAO,SAAS,MAAM,yBAAyB,CAAC;AAGhD,OAAO,OAGN,MAAM,wCAAwC,CAAC;AAEhD,MAAM,UAAU,sBAAsB,CACpC,OAAgB,EAChB,SAAqD;IAErD,SAAS,CAAC,SAAS,GAAG,OAAO,CAAC;AAChC,CAAC;AAED,SAAS,mBAAmB,CAC1B,IAAmB,EACnB,UAA+B;IAE/B,MAAM,EAAE,MAAM,EAAE,GAAG,UAAU,CAAC;IAC9B,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,MAAM,EAAE,CAAC,EAAE,EAAE,CAAC;QAChC,MAAM,CAAC,GAAG,UAAU,CAAC,GAAG,CAAC,CAAC,CAAkB,CAAC;QAC7C,IAAI,CAAC,KAAK,IAAI,EAAE,CAAC;YACf,OAAO,CAAC,CAAC;QACX,CAAC;IACH,CAAC;IACD,OAAO,CAAC,CAAC,CAAC;AACZ,CAAC;AAED,SAAS,mBAAmB,CAC1B,IAA4B,EAC5B,IAAmB,EACn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;YAC3C,OAAO,CAAC,IAAI,CAAC,CAAC;QAChB,CAAC,CAAC,CAAC;QACH,IAAI,CAAC,mBAAmB,CAAC,KAAK,EAAE,CAAC;IACnC,CAAC;IAED;;OAEG;IACH,OAAO;QACL,IAAI,IAAI,CAAC,eAAe,EAAE,CAAC;YACzB,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;YAC7C,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,IAAI,CAAC,gBAAgB,CAAC,CAAC;YACnD,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,CAAC;YAC7C,IAAI,CAAC,eAAe,CAAC,MAAM,CAAC,IAAI,CAAC,MAAM,CAAC,CAAC;QAC3C,CAAC;QACD,6DAA6D;QAC7D,aAAa;QACb,IAAI,CAAC,eAAe,GAAG,IAAI,CAAC;QAC5B,IAAI,CAAC,mBAAmB,CAAC,OAAO,CAAC,CAAC,OAAO,EAAE,EAAE;YAC3C,OAAO,CAAC,IAAI,CAAC,CAAC;QAChB,CAAC,CAAC,CAAC;QACH,IAAI,CAAC,mBAAmB,CAAC,KAAK,EAAE,CAAC;QACjC,IAAI,CAAC,aAAa,CAAC,KAAK,EAAE,CAAC;QAC3B,IAAI,CAAC,mBAAmB,EAAE,CAAC;IAC7B,CAAC;CACF"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Symbol to declare a layers name on its visualizations, e.g. ol.layer.Layer, Cesium.Cesium3DTileset*
|
|
3
3
|
*/
|
|
4
|
-
|
|
4
|
+
// eslint-disable-next-line import/prefer-default-export
|
|
5
5
|
export const vcsLayerName = Symbol('vcsLayerName');
|
|
6
6
|
//# sourceMappingURL=layerSymbols.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"layerSymbols.js","sourceRoot":"","sources":["../../../src/layer/layerSymbols.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,
|
|
1
|
+
{"version":3,"file":"layerSymbols.js","sourceRoot":"","sources":["../../../src/layer/layerSymbols.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,wDAAwD;AACxD,MAAM,CAAC,MAAM,YAAY,GAAkB,MAAM,CAAC,cAAc,CAAC,CAAC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import VectorSource from 'ol/source/Vector.js';
|
|
2
|
+
import ObliqueMap from '../../map/obliqueMap.js';
|
|
3
|
+
export type SourceObliqueSync = {
|
|
4
|
+
readonly active: boolean;
|
|
5
|
+
readonly obliqueSource: VectorSource;
|
|
6
|
+
activate(): void;
|
|
7
|
+
deactivate(): void;
|
|
8
|
+
destroy(): void;
|
|
9
|
+
};
|
|
10
|
+
/**
|
|
11
|
+
* Creates a SourceObliqueSync. This ensures that the features in the source are synced to the oblique source.
|
|
12
|
+
* Adding, removing and changing features in the source will be reflected in the oblique source. Changing the oblique geometry will
|
|
13
|
+
* be synced back onto the original geometry. Changing the geometry will create a new oblique geometry on the same feature.
|
|
14
|
+
* Feature changes will lead to an update of style.
|
|
15
|
+
* @param source
|
|
16
|
+
* @param map
|
|
17
|
+
*/
|
|
18
|
+
export declare function createSourceObliqueSync(source: VectorSource, map: ObliqueMap): SourceObliqueSync;
|