bruce-cesium 2.8.9 → 2.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/dist/bruce-cesium.es5.js +50 -55
- package/dist/bruce-cesium.es5.js.map +1 -1
- package/dist/bruce-cesium.umd.js +49 -54
- package/dist/bruce-cesium.umd.js.map +1 -1
- package/dist/lib/bruce-cesium.js +1 -1
- package/dist/lib/rendering/render-managers/entities/entities-loaded-render-manager.js +6 -0
- package/dist/lib/rendering/render-managers/entities/entities-loaded-render-manager.js.map +1 -1
- package/dist/lib/rendering/render-managers/other/relations-render-manager.js +2 -11
- package/dist/lib/rendering/render-managers/other/relations-render-manager.js.map +1 -1
- package/dist/lib/rendering/view-render-engine.js +40 -42
- package/dist/lib/rendering/view-render-engine.js.map +1 -1
- package/dist/lib/utils/view-utils.js.map +1 -1
- package/dist/types/bruce-cesium.d.ts +1 -1
- package/package.json +2 -2
package/dist/bruce-cesium.es5.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { BruceEvent, Cartes, Carto, Entity as Entity$1, Geometry, Tileset, MathUtils, LRUCache, ZoomControl, Style, EntityTag, Calculator, EntityLod, EntityType, ClientFile, ObjectUtils, Bounds, EntityRelationType, DelayQueue, BatchedDataGetter, EntityCoords, EntityFilterGetter, EntitySource, MenuItem, EntityRelation, ENVIRONMENT, ProjectView, ProjectViewBookmark, ProjectViewTile, ProjectViewLegacyTile, ProgramKey, Camera, AbstractApi, EntityAttachment, EntityAttachmentType, EntityAttribute } from 'bruce-models';
|
|
2
2
|
import * as Cesium from 'cesium';
|
|
3
|
-
import { Cartographic, Cartesian2, CallbackProperty, Cartesian3, Color, Rectangle, Math as Math$1, JulianDate,
|
|
3
|
+
import { Cartographic, Cartesian2, CallbackProperty, Cartesian3, Color, Rectangle, Math as Math$1, JulianDate, Entity, Primitive, Cesium3DTileFeature, HeightReference, DistanceDisplayCondition, NearFarScalar, HorizontalOrigin, VerticalOrigin, ClassificationType, ArcType, CornerType, ShadowMode, PolygonHierarchy, PolylineGraphics, HeadingPitchRoll, Transforms, ColorBlendMode, SceneMode, HeadingPitchRange, Cesium3DTileColorBlendMode, createOsmBuildings, Cesium3DTileStyle, KmlDataSource, OrthographicFrustum, EasingFunction, SceneTransforms, createWorldTerrain, EllipsoidTerrainProvider, CesiumTerrainProvider, BingMapsImageryProvider, BingMapsStyle, MapboxImageryProvider, MapboxStyleImageryProvider, ArcGisMapServerImageryProvider, OpenStreetMapImageryProvider, GridImageryProvider, GeographicTilingScheme, ImageryLayer, UrlTemplateImageryProvider, TileMapServiceImageryProvider, IonImageryProvider, CesiumInspector, defined, Cesium3DTileset, Matrix4, Matrix3, IonResource, Ion, EllipsoidGeodesic, sampleTerrainMostDetailed, Model, PolygonPipeline, ScreenSpaceEventHandler, ScreenSpaceEventType, ColorMaterialProperty, GeometryInstance, BoundingSphere } from 'cesium';
|
|
4
4
|
|
|
5
5
|
var TIME_LAG = 300;
|
|
6
6
|
var POSITION_CHECK_TIMER = 950;
|
|
@@ -6834,6 +6834,12 @@ var EntitiesLoadedRenderManager;
|
|
|
6834
6834
|
})];
|
|
6835
6835
|
case 1:
|
|
6836
6836
|
cEntities = _b.sent();
|
|
6837
|
+
if (this.disposed) {
|
|
6838
|
+
this.visualsManager.RemoveRegos({
|
|
6839
|
+
menuItemId: this.item.id
|
|
6840
|
+
});
|
|
6841
|
+
return [2 /*return*/];
|
|
6842
|
+
}
|
|
6837
6843
|
for (i = 0; i < entities.length; i++) {
|
|
6838
6844
|
entity = entities[i];
|
|
6839
6845
|
id = entity.Bruce.ID;
|
|
@@ -10011,17 +10017,8 @@ var RelationsRenderManager;
|
|
|
10011
10017
|
* @param relation
|
|
10012
10018
|
*/
|
|
10013
10019
|
Manager.prototype.shouldRenderRelation = function (relation) {
|
|
10014
|
-
var _a, _b
|
|
10015
|
-
|
|
10016
|
-
// Find group for the same relationship type.
|
|
10017
|
-
var typeRelations = this.item.relations.find(function (x) { return x.relationTypeId == relation["Relation.Type.ID"]; });
|
|
10018
|
-
// See if group contains the parent entity ID.
|
|
10019
|
-
if ((_b = typeRelations === null || typeRelations === void 0 ? void 0 : typeRelations.entityIds) === null || _b === void 0 ? void 0 : _b.find(function (x) { return x == relation["Principal.Entity.ID"]; })) {
|
|
10020
|
-
return true;
|
|
10021
|
-
}
|
|
10022
|
-
}
|
|
10023
|
-
// Backwards compatability.
|
|
10024
|
-
var renderedIds = (_d = (_c = this.item) === null || _c === void 0 ? void 0 : _c.BruceEntity) === null || _d === void 0 ? void 0 : _d.EntityIds;
|
|
10020
|
+
var _a, _b;
|
|
10021
|
+
var renderedIds = (_b = (_a = this.item) === null || _a === void 0 ? void 0 : _a.BruceEntity) === null || _b === void 0 ? void 0 : _b.EntityIds;
|
|
10025
10022
|
if (!renderedIds) {
|
|
10026
10023
|
return false;
|
|
10027
10024
|
}
|
|
@@ -12806,7 +12803,6 @@ function assertIteration$1(viewer, iteration) {
|
|
|
12806
12803
|
}
|
|
12807
12804
|
/**
|
|
12808
12805
|
* Renders DATA_VERSION = 1 navigator.
|
|
12809
|
-
* param iteration
|
|
12810
12806
|
* @param params
|
|
12811
12807
|
* @param bookmark
|
|
12812
12808
|
* @param view
|
|
@@ -12930,32 +12926,33 @@ function renderLegacyNavigator(iteration, params, bookmark, view) {
|
|
|
12930
12926
|
}
|
|
12931
12927
|
_f.label = 3;
|
|
12932
12928
|
case 3:
|
|
12933
|
-
if ((_e = bSettings === null || bSettings === void 0 ? void 0 : bSettings.drawnRelationEntityIDs) === null || _e === void 0 ? void 0 : _e.length)
|
|
12934
|
-
|
|
12935
|
-
|
|
12936
|
-
|
|
12937
|
-
|
|
12938
|
-
|
|
12939
|
-
|
|
12940
|
-
|
|
12941
|
-
|
|
12942
|
-
|
|
12929
|
+
if (!((_e = bSettings === null || bSettings === void 0 ? void 0 : bSettings.drawnRelationEntityIDs) === null || _e === void 0 ? void 0 : _e.length)) return [3 /*break*/, 5];
|
|
12930
|
+
menuItem = {
|
|
12931
|
+
id: RELATION_MENU_ITEM_ID,
|
|
12932
|
+
Caption: "Entity relations",
|
|
12933
|
+
BruceEntity: {
|
|
12934
|
+
EntityIds: bSettings.drawnRelationEntityIDs
|
|
12935
|
+
},
|
|
12936
|
+
Type: MenuItem.EType.Relations
|
|
12937
|
+
};
|
|
12938
|
+
return [4 /*yield*/, params.manager.RenderItem({
|
|
12943
12939
|
apiGetter: params.apiGetter,
|
|
12944
12940
|
getters: params.getters,
|
|
12945
12941
|
item: menuItem
|
|
12946
|
-
});
|
|
12947
|
-
|
|
12948
|
-
|
|
12949
|
-
|
|
12942
|
+
})];
|
|
12943
|
+
case 4:
|
|
12944
|
+
_f.sent();
|
|
12945
|
+
if (!assertIteration$1(params.viewer, iteration)) {
|
|
12946
|
+
return [2 /*return*/];
|
|
12950
12947
|
}
|
|
12951
|
-
|
|
12948
|
+
_f.label = 5;
|
|
12949
|
+
case 5: return [2 /*return*/];
|
|
12952
12950
|
}
|
|
12953
12951
|
});
|
|
12954
12952
|
});
|
|
12955
12953
|
}
|
|
12956
12954
|
/**
|
|
12957
12955
|
* Renders DATA_VERSION > 1 navigator.
|
|
12958
|
-
* @param iteration
|
|
12959
12956
|
* @param params
|
|
12960
12957
|
* @param bookmark
|
|
12961
12958
|
* @param view
|
|
@@ -12963,7 +12960,7 @@ function renderLegacyNavigator(iteration, params, bookmark, view) {
|
|
|
12963
12960
|
function renderNavigator(iteration, params, bookmark, view) {
|
|
12964
12961
|
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _0, _1, _2, _3, _4, _5, _6;
|
|
12965
12962
|
return __awaiter(this, void 0, void 0, function () {
|
|
12966
|
-
var viewer, scene, vSettings, bSettings, defaults, camera, newLens, shouldBe2d, curIs2d, transition, pos, terrain, hillShades, baseColor, globeHidden, terrainWireframe, globeAlpha, shadows, size, ambientOcclusion, AO, lighting, light, quality, fxaa, dateTime, clock, selectedIds, hiddenIds, isolatedIds, labelledIds, curLabelledIds, toUnLabel, entityOpacityMap, entityId, opacity, imagery,
|
|
12963
|
+
var viewer, scene, vSettings, bSettings, defaults, camera, newLens, shouldBe2d, curIs2d, transition, pos, terrain, hillShades, baseColor, globeHidden, terrainWireframe, globeAlpha, shadows, size, ambientOcclusion, AO, lighting, light, quality, fxaa, dateTime, clock, selectedIds, hiddenIds, isolatedIds, labelledIds, curLabelledIds, toUnLabel, entityOpacityMap, entityId, opacity, imagery, renderedRelationEntityIds, curEnabled, newItemIds, _i, curEnabled_1, id, menuItem, gOcclusion;
|
|
12967
12964
|
return __generator(this, function (_7) {
|
|
12968
12965
|
switch (_7.label) {
|
|
12969
12966
|
case 0:
|
|
@@ -13249,20 +13246,16 @@ function renderNavigator(iteration, params, bookmark, view) {
|
|
|
13249
13246
|
tiles: imagery,
|
|
13250
13247
|
viewer: params.manager.Viewer,
|
|
13251
13248
|
});
|
|
13252
|
-
|
|
13253
|
-
if (!
|
|
13254
|
-
|
|
13255
|
-
}
|
|
13256
|
-
relations = bSettings === null || bSettings === void 0 ? void 0 : bSettings.renderedRelations;
|
|
13257
|
-
if (!relations) {
|
|
13258
|
-
relations = [];
|
|
13249
|
+
renderedRelationEntityIds = bSettings === null || bSettings === void 0 ? void 0 : bSettings.renderedEntityRelations;
|
|
13250
|
+
if (!renderedRelationEntityIds) {
|
|
13251
|
+
renderedRelationEntityIds = [];
|
|
13259
13252
|
}
|
|
13260
13253
|
curEnabled = params.manager.GetEnabledItemIds();
|
|
13261
13254
|
newItemIds = (_5 = bSettings === null || bSettings === void 0 ? void 0 : bSettings.menuItemIds) !== null && _5 !== void 0 ? _5 : [];
|
|
13262
13255
|
for (_i = 0, curEnabled_1 = curEnabled; _i < curEnabled_1.length; _i++) {
|
|
13263
13256
|
id = curEnabled_1[_i];
|
|
13264
|
-
if (
|
|
13265
|
-
(id == RELATION_MENU_ITEM_ID && !
|
|
13257
|
+
if (newItemIds.indexOf(id) === -1 ||
|
|
13258
|
+
(id == RELATION_MENU_ITEM_ID && !renderedRelationEntityIds.length)) {
|
|
13266
13259
|
params.manager.RemoveItemById({
|
|
13267
13260
|
menuItemId: id
|
|
13268
13261
|
});
|
|
@@ -13282,24 +13275,26 @@ function renderNavigator(iteration, params, bookmark, view) {
|
|
|
13282
13275
|
}
|
|
13283
13276
|
_7.label = 4;
|
|
13284
13277
|
case 4:
|
|
13285
|
-
if (
|
|
13286
|
-
|
|
13287
|
-
|
|
13288
|
-
|
|
13289
|
-
|
|
13290
|
-
|
|
13291
|
-
|
|
13292
|
-
|
|
13293
|
-
|
|
13294
|
-
|
|
13295
|
-
params.manager.RenderItem({
|
|
13278
|
+
if (!renderedRelationEntityIds.length) return [3 /*break*/, 6];
|
|
13279
|
+
menuItem = {
|
|
13280
|
+
id: RELATION_MENU_ITEM_ID,
|
|
13281
|
+
Caption: "Entity relations",
|
|
13282
|
+
BruceEntity: {
|
|
13283
|
+
EntityIds: renderedRelationEntityIds
|
|
13284
|
+
},
|
|
13285
|
+
Type: MenuItem.EType.Relations
|
|
13286
|
+
};
|
|
13287
|
+
return [4 /*yield*/, params.manager.RenderItem({
|
|
13296
13288
|
getters: params.getters,
|
|
13297
13289
|
item: menuItem
|
|
13298
|
-
});
|
|
13299
|
-
|
|
13300
|
-
|
|
13301
|
-
|
|
13290
|
+
})];
|
|
13291
|
+
case 5:
|
|
13292
|
+
_7.sent();
|
|
13293
|
+
if (!assertIteration$1(params.viewer, iteration)) {
|
|
13294
|
+
return [2 /*return*/];
|
|
13302
13295
|
}
|
|
13296
|
+
_7.label = 6;
|
|
13297
|
+
case 6:
|
|
13303
13298
|
gOcclusion = bSettings === null || bSettings === void 0 ? void 0 : bSettings.groundOcclusion;
|
|
13304
13299
|
if (gOcclusion == null) {
|
|
13305
13300
|
gOcclusion = (_6 = defaults === null || defaults === void 0 ? void 0 : defaults.settings) === null || _6 === void 0 ? void 0 : _6.groundOcclusion;
|
|
@@ -16213,7 +16208,7 @@ var ViewerUtils;
|
|
|
16213
16208
|
ViewerUtils.CreateWidgets = CreateWidgets;
|
|
16214
16209
|
})(ViewerUtils || (ViewerUtils = {}));
|
|
16215
16210
|
|
|
16216
|
-
var VERSION$1 = "2.
|
|
16211
|
+
var VERSION$1 = "2.9.1";
|
|
16217
16212
|
|
|
16218
16213
|
export { VERSION$1 as VERSION, CesiumViewMonitor, ViewerUtils, MenuItemManager, EntityRenderEngine, MenuItemCreator, VisualsRegister, RenderManager, EntitiesIdsRenderManager, EntitiesLoadedRenderManager, EntitiesRenderManager, EntityRenderManager, TilesetCadRenderManager, TilesetArbRenderManager, TilesetEntitiesRenderManager, TilesetOsmRenderManager, TilesetPointcloudRenderManager, TilesetGooglePhotosRenderManager, DataSourceStaticKmlManager, RelationsRenderManager, SharedGetters, CesiumParabola, EntityLabel, ViewRenderEngine, TileRenderEngine, TilesetRenderEngine, CESIUM_INSPECTOR_KEY, ViewUtils, DrawingUtils, MeasureUtils, EntityUtils, Draw3dPolygon, Draw3dPolyline };
|
|
16219
16214
|
//# sourceMappingURL=bruce-cesium.es5.js.map
|