bruce-cesium 3.7.2 → 3.7.4
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/bruce-cesium.es5.js +1032 -266
- package/dist/bruce-cesium.es5.js.map +1 -1
- package/dist/bruce-cesium.umd.js +1030 -264
- package/dist/bruce-cesium.umd.js.map +1 -1
- package/dist/lib/bruce-cesium.js +1 -1
- package/dist/lib/rendering/cesium-animated-property.js +280 -0
- package/dist/lib/rendering/cesium-animated-property.js.map +1 -0
- package/dist/lib/rendering/entity-render-engine.js +628 -254
- package/dist/lib/rendering/entity-render-engine.js.map +1 -1
- package/dist/lib/rendering/tileset-render-engine.js +10 -0
- package/dist/lib/rendering/tileset-render-engine.js.map +1 -1
- package/dist/lib/utils/cesium-entity-styler.js +115 -5
- package/dist/lib/utils/cesium-entity-styler.js.map +1 -1
- package/dist/lib/utils/entity-utils.js +0 -1
- package/dist/lib/utils/entity-utils.js.map +1 -1
- package/dist/types/bruce-cesium.d.ts +1 -1
- package/dist/types/rendering/cesium-animated-property.d.ts +88 -0
- package/dist/types/rendering/entity-render-engine.d.ts +10 -1
- package/dist/types/utils/cesium-entity-styler.d.ts +5 -0
- package/package.json +1 -1
package/dist/lib/bruce-cesium.js
CHANGED
|
@@ -47,5 +47,5 @@ __exportStar(require("./utils/entity-utils"), exports);
|
|
|
47
47
|
__exportStar(require("./utils/cesium-entity-styler"), exports);
|
|
48
48
|
__exportStar(require("./widgets/common/draw-3d-polygon"), exports);
|
|
49
49
|
__exportStar(require("./widgets/common/draw-3d-polyline"), exports);
|
|
50
|
-
exports.VERSION = "3.7.
|
|
50
|
+
exports.VERSION = "3.7.4";
|
|
51
51
|
//# sourceMappingURL=bruce-cesium.js.map
|
|
@@ -0,0 +1,280 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.CesiumAnimatedProperty = void 0;
|
|
4
|
+
var Cesium = require("cesium");
|
|
5
|
+
function getColor(viewer, obj) {
|
|
6
|
+
var value = null;
|
|
7
|
+
if (obj === null || obj === void 0 ? void 0 : obj.getValue) {
|
|
8
|
+
var date = viewer.scene.lastRenderTime;
|
|
9
|
+
if (!date) {
|
|
10
|
+
date = viewer.clock.currentTime;
|
|
11
|
+
}
|
|
12
|
+
value = obj.getValue(date);
|
|
13
|
+
}
|
|
14
|
+
else {
|
|
15
|
+
value = obj;
|
|
16
|
+
}
|
|
17
|
+
if (value && value instanceof Cesium.ColorMaterialProperty) {
|
|
18
|
+
value = value.color;
|
|
19
|
+
}
|
|
20
|
+
return value;
|
|
21
|
+
}
|
|
22
|
+
function getNumber(viewer, obj) {
|
|
23
|
+
var value = null;
|
|
24
|
+
if (obj === null || obj === void 0 ? void 0 : obj.getValue) {
|
|
25
|
+
var date = viewer.scene.lastRenderTime;
|
|
26
|
+
if (!date) {
|
|
27
|
+
date = viewer.clock.currentTime;
|
|
28
|
+
}
|
|
29
|
+
value = obj.getValue(date);
|
|
30
|
+
}
|
|
31
|
+
else {
|
|
32
|
+
value = obj;
|
|
33
|
+
}
|
|
34
|
+
return value;
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* Returns if a given visual is alive and in the scene.
|
|
38
|
+
* @param viewer
|
|
39
|
+
* @param visual
|
|
40
|
+
* @returns
|
|
41
|
+
*/
|
|
42
|
+
function isFeatureAlive(viewer, feature) {
|
|
43
|
+
if (!(viewer === null || viewer === void 0 ? void 0 : viewer.scene) || viewer.isDestroyed()) {
|
|
44
|
+
return false;
|
|
45
|
+
}
|
|
46
|
+
var cTileset = feature === null || feature === void 0 ? void 0 : feature.tileset;
|
|
47
|
+
if (!cTileset) {
|
|
48
|
+
return false;
|
|
49
|
+
}
|
|
50
|
+
if (cTileset.isDestroyed() || !viewer.scene.primitives.contains(cTileset)) {
|
|
51
|
+
return false;
|
|
52
|
+
}
|
|
53
|
+
return true;
|
|
54
|
+
}
|
|
55
|
+
var _lastMark = 0;
|
|
56
|
+
var generateMark = function () {
|
|
57
|
+
_lastMark += 1;
|
|
58
|
+
return _lastMark;
|
|
59
|
+
};
|
|
60
|
+
function setMark(color, mark) {
|
|
61
|
+
color["NEXTSPACE_PROPERTY_MARK"] = mark;
|
|
62
|
+
}
|
|
63
|
+
function assertColorMark(mark, color) {
|
|
64
|
+
return color["NEXTSPACE_PROPERTY_MARK"] == mark;
|
|
65
|
+
}
|
|
66
|
+
var CesiumAnimatedProperty;
|
|
67
|
+
(function (CesiumAnimatedProperty) {
|
|
68
|
+
/**
|
|
69
|
+
* Example:
|
|
70
|
+
* ```
|
|
71
|
+
* const myEntity = null; // Get an Entity from somewhere.
|
|
72
|
+
*
|
|
73
|
+
* const animateColor = new AnimateColor({
|
|
74
|
+
* viewer: viewer,
|
|
75
|
+
* color: Cesium.Color.RED,
|
|
76
|
+
* startColor: myEntity.model.color,
|
|
77
|
+
* type: "LINEAR",
|
|
78
|
+
* durationMs: 1000
|
|
79
|
+
* });
|
|
80
|
+
*
|
|
81
|
+
* myEntity.model.color = new Cesium.CallbackProperty(() => {
|
|
82
|
+
* return animateColor.GetValue();
|
|
83
|
+
* }, false);
|
|
84
|
+
* ```
|
|
85
|
+
*/
|
|
86
|
+
var AnimateColor = /** @class */ (function () {
|
|
87
|
+
function AnimateColor(params) {
|
|
88
|
+
var _a;
|
|
89
|
+
this.viewer = params.viewer;
|
|
90
|
+
this.color = params.color;
|
|
91
|
+
this.durationMs = params.durationMs;
|
|
92
|
+
this.startColor = getColor(this.viewer, params.startColor);
|
|
93
|
+
if ((_a = this.startColor) === null || _a === void 0 ? void 0 : _a.clone) {
|
|
94
|
+
this.startColor = this.startColor.clone();
|
|
95
|
+
}
|
|
96
|
+
if (!this.startColor) {
|
|
97
|
+
this.startColor = Cesium.Color.WHITE.clone();
|
|
98
|
+
console.warn("No start color provided. Using WHITE as start color. Animation may not work as expected.");
|
|
99
|
+
}
|
|
100
|
+
this.startTime = new Date();
|
|
101
|
+
}
|
|
102
|
+
/**
|
|
103
|
+
* Returns the calculated color at the provided time.
|
|
104
|
+
* @returns
|
|
105
|
+
*/
|
|
106
|
+
AnimateColor.prototype.GetColor = function () {
|
|
107
|
+
var now = new Date();
|
|
108
|
+
var elapsedMs = now.getTime() - this.startTime.getTime();
|
|
109
|
+
// Animation over.
|
|
110
|
+
if (elapsedMs >= this.durationMs) {
|
|
111
|
+
return this.color;
|
|
112
|
+
}
|
|
113
|
+
try {
|
|
114
|
+
var progress = elapsedMs / this.durationMs;
|
|
115
|
+
return Cesium.Color.lerp(this.startColor, this.color, progress, new Cesium.Color());
|
|
116
|
+
}
|
|
117
|
+
catch (e) {
|
|
118
|
+
console.error(e);
|
|
119
|
+
}
|
|
120
|
+
// Failed to calculate color.
|
|
121
|
+
// We'll just return the target color.
|
|
122
|
+
return this.color;
|
|
123
|
+
};
|
|
124
|
+
/**
|
|
125
|
+
* Returns the calculated color as a material property.
|
|
126
|
+
* @returns
|
|
127
|
+
*/
|
|
128
|
+
AnimateColor.prototype.GetMaterial = function () {
|
|
129
|
+
var color = this.GetColor();
|
|
130
|
+
return new Cesium.ColorMaterialProperty(color);
|
|
131
|
+
};
|
|
132
|
+
return AnimateColor;
|
|
133
|
+
}());
|
|
134
|
+
CesiumAnimatedProperty.AnimateColor = AnimateColor;
|
|
135
|
+
var AnimateNumber = /** @class */ (function () {
|
|
136
|
+
function AnimateNumber(params) {
|
|
137
|
+
this.paused = false;
|
|
138
|
+
this.paused = Boolean(params.startPaused);
|
|
139
|
+
this.viewer = params.viewer;
|
|
140
|
+
this.value = params.value;
|
|
141
|
+
this.durationMs = params.durationMs;
|
|
142
|
+
this.startValue = getNumber(this.viewer, params.startValue);
|
|
143
|
+
if (!this.startValue) {
|
|
144
|
+
this.startValue = 0;
|
|
145
|
+
}
|
|
146
|
+
if (!this.paused) {
|
|
147
|
+
this.startTime = new Date();
|
|
148
|
+
}
|
|
149
|
+
}
|
|
150
|
+
AnimateNumber.prototype.Play = function () {
|
|
151
|
+
if (this.paused) {
|
|
152
|
+
this.paused = false;
|
|
153
|
+
this.startTime = new Date();
|
|
154
|
+
}
|
|
155
|
+
};
|
|
156
|
+
AnimateNumber.prototype.GetValue = function () {
|
|
157
|
+
if (this.paused) {
|
|
158
|
+
return this.startValue;
|
|
159
|
+
}
|
|
160
|
+
var now = new Date();
|
|
161
|
+
var elapsedMs = now.getTime() - this.startTime.getTime();
|
|
162
|
+
// Animation over.
|
|
163
|
+
if (elapsedMs >= this.durationMs) {
|
|
164
|
+
return this.value;
|
|
165
|
+
}
|
|
166
|
+
try {
|
|
167
|
+
var progress = elapsedMs / this.durationMs;
|
|
168
|
+
return Cesium.Math.lerp(this.startValue, this.value, progress);
|
|
169
|
+
}
|
|
170
|
+
catch (e) {
|
|
171
|
+
console.error(e);
|
|
172
|
+
}
|
|
173
|
+
// Failed to calculate value.
|
|
174
|
+
// We'll just return the target value.
|
|
175
|
+
return this.value;
|
|
176
|
+
};
|
|
177
|
+
return AnimateNumber;
|
|
178
|
+
}());
|
|
179
|
+
CesiumAnimatedProperty.AnimateNumber = AnimateNumber;
|
|
180
|
+
/**
|
|
181
|
+
* Animates the color of a feature.
|
|
182
|
+
* This is handled separately from the AnimateColor class as Tileset features do not support Cesium callback properties.
|
|
183
|
+
*
|
|
184
|
+
* Example:
|
|
185
|
+
* ```
|
|
186
|
+
* const animateColor = AnimateTFeatureColor({
|
|
187
|
+
* viewer: viewer,
|
|
188
|
+
* feature: feature,
|
|
189
|
+
* color: Cesium.Color.RED,
|
|
190
|
+
* startColor: feature.color,
|
|
191
|
+
* durationMs: 1000
|
|
192
|
+
* });
|
|
193
|
+
* ```
|
|
194
|
+
* @param params
|
|
195
|
+
* @returns
|
|
196
|
+
*/
|
|
197
|
+
function AnimateTFeatureColor(params) {
|
|
198
|
+
var viewer = params.viewer, feature = params.feature, color = params.color, startColor = params.startColor, durationMs = params.durationMs;
|
|
199
|
+
ClearTFeatureColorAnimation(feature);
|
|
200
|
+
if (!startColor) {
|
|
201
|
+
if (feature.color) {
|
|
202
|
+
startColor = feature.color;
|
|
203
|
+
if (startColor.clone) {
|
|
204
|
+
startColor = startColor.clone();
|
|
205
|
+
}
|
|
206
|
+
}
|
|
207
|
+
else {
|
|
208
|
+
startColor = Cesium.Color.WHITE.clone();
|
|
209
|
+
}
|
|
210
|
+
}
|
|
211
|
+
// Don't animate if the colour is the same.
|
|
212
|
+
var curColor = getColor(viewer, feature.color);
|
|
213
|
+
if (curColor && Cesium.Color.WHITE.equals(curColor)) {
|
|
214
|
+
curColor = null;
|
|
215
|
+
}
|
|
216
|
+
var colorTmp = color == null || Cesium.Color.WHITE.equals(color) ? null : color;
|
|
217
|
+
if (!curColor && !colorTmp) {
|
|
218
|
+
return function () { };
|
|
219
|
+
}
|
|
220
|
+
else if (curColor && colorTmp && curColor.equals(colorTmp)) {
|
|
221
|
+
return function () { };
|
|
222
|
+
}
|
|
223
|
+
// Marks are used to detect external changes to the feature's color.
|
|
224
|
+
// If an external change is detected, the animation will stop.
|
|
225
|
+
var mark = generateMark();
|
|
226
|
+
setMark(feature.color, mark);
|
|
227
|
+
setMark(startColor, mark);
|
|
228
|
+
setMark(color, mark);
|
|
229
|
+
var startTime = new Date();
|
|
230
|
+
var removal = viewer.scene.postUpdate.addEventListener(function () {
|
|
231
|
+
if (!isFeatureAlive(viewer, feature)) {
|
|
232
|
+
removal === null || removal === void 0 ? void 0 : removal();
|
|
233
|
+
removal = null;
|
|
234
|
+
return;
|
|
235
|
+
}
|
|
236
|
+
if (!assertColorMark(mark, feature.color)) {
|
|
237
|
+
removal === null || removal === void 0 ? void 0 : removal();
|
|
238
|
+
removal = null;
|
|
239
|
+
return;
|
|
240
|
+
}
|
|
241
|
+
var now = new Date();
|
|
242
|
+
var elapsedMs = now.getTime() - startTime.getTime();
|
|
243
|
+
// Animation over.
|
|
244
|
+
if (elapsedMs >= durationMs) {
|
|
245
|
+
feature.color = color;
|
|
246
|
+
removal === null || removal === void 0 ? void 0 : removal();
|
|
247
|
+
removal = null;
|
|
248
|
+
return;
|
|
249
|
+
}
|
|
250
|
+
try {
|
|
251
|
+
var progress = elapsedMs / durationMs;
|
|
252
|
+
var newColor = Cesium.Color.lerp(startColor, color, progress, new Cesium.Color());
|
|
253
|
+
setMark(newColor, mark);
|
|
254
|
+
feature.color = newColor;
|
|
255
|
+
return;
|
|
256
|
+
}
|
|
257
|
+
catch (e) {
|
|
258
|
+
console.error(e);
|
|
259
|
+
}
|
|
260
|
+
// Failed to calculate color.
|
|
261
|
+
// We'll just set the target color and stop the animation.
|
|
262
|
+
feature.color = color;
|
|
263
|
+
});
|
|
264
|
+
// Return a function to stop the animation.
|
|
265
|
+
feature["ANIMATED_COLOR_REMOVAL"] = removal;
|
|
266
|
+
return function () {
|
|
267
|
+
removal === null || removal === void 0 ? void 0 : removal();
|
|
268
|
+
removal = null;
|
|
269
|
+
};
|
|
270
|
+
}
|
|
271
|
+
CesiumAnimatedProperty.AnimateTFeatureColor = AnimateTFeatureColor;
|
|
272
|
+
function ClearTFeatureColorAnimation(feature) {
|
|
273
|
+
if (feature && feature["ANIMATED_COLOR_REMOVAL"]) {
|
|
274
|
+
feature["ANIMATED_COLOR_REMOVAL"]();
|
|
275
|
+
feature["ANIMATED_COLOR_REMOVAL"] = null;
|
|
276
|
+
}
|
|
277
|
+
}
|
|
278
|
+
CesiumAnimatedProperty.ClearTFeatureColorAnimation = ClearTFeatureColorAnimation;
|
|
279
|
+
})(CesiumAnimatedProperty = exports.CesiumAnimatedProperty || (exports.CesiumAnimatedProperty = {}));
|
|
280
|
+
//# sourceMappingURL=cesium-animated-property.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cesium-animated-property.js","sourceRoot":"","sources":["../../../src/rendering/cesium-animated-property.ts"],"names":[],"mappings":";;;AAAA,+BAAiC;AAEjC,SAAS,QAAQ,CAAC,MAAqB,EAAE,GAA0B;IAC/D,IAAI,KAAK,GAAG,IAAI,CAAC;IACjB,IAAK,GAAW,aAAX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