bruce-cesium 4.6.8 → 4.7.0
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 +25 -10
- package/dist/bruce-cesium.es5.js.map +1 -1
- package/dist/bruce-cesium.umd.js +23 -8
- package/dist/bruce-cesium.umd.js.map +1 -1
- package/dist/lib/bruce-cesium.js +1 -1
- package/dist/lib/rendering/getters/entity-filter-getter.js +8 -0
- package/dist/lib/rendering/getters/entity-filter-getter.js.map +1 -1
- package/dist/lib/rendering/render-managers/tilesets/tileset-arb-render-manager.js +1 -1
- package/dist/lib/rendering/render-managers/tilesets/tileset-arb-render-manager.js.map +1 -1
- package/dist/lib/rendering/render-managers/tilesets/tileset-cad-render-manager.js +2 -1
- package/dist/lib/rendering/render-managers/tilesets/tileset-cad-render-manager.js.map +1 -1
- package/dist/lib/rendering/render-managers/tilesets/tileset-entities-render-manager.js +1 -1
- package/dist/lib/rendering/render-managers/tilesets/tileset-entities-render-manager.js.map +1 -1
- package/dist/lib/rendering/tileset-render-engine.js +9 -3
- package/dist/lib/rendering/tileset-render-engine.js.map +1 -1
- package/dist/lib/widgets/common/measure-creator.js +1 -1
- package/dist/lib/widgets/common/measure-creator.js.map +1 -1
- package/dist/types/bruce-cesium.d.ts +1 -1
- package/dist/types/rendering/tileset-render-engine.d.ts +3 -1
- package/package.json +2 -2
package/dist/bruce-cesium.es5.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { BruceEvent, Cartes, Entity as Entity$1, Carto, Geometry, MathUtils, LRUCache, Api, Calculator, ClientFile, EntityTag, EntityType, ObjectUtils, Style, ProjectViewTile, DelayQueue, EntityLod, Bounds, ZoomControl, EntityRelationType, ENVIRONMENT, EntityHistoricData, Tileset, EntityCoords, EntitySource, MenuItem, EntityRelation, ProgramKey, ProjectView, ProjectViewBookmark, Camera, ProjectViewLegacyTile, EntityAttribute, EntityAttachment, EntityAttachmentType,
|
|
1
|
+
import { BruceEvent, Cartes, Entity as Entity$1, Carto, Geometry, MathUtils, LRUCache, Api, Calculator, ClientFile, EntityTag, EntityType, ObjectUtils, Style, ProjectViewTile, DelayQueue, EntityLod, Bounds, ZoomControl, EntityRelationType, ENVIRONMENT, EntityHistoricData, Tileset, EntityCoords, EntitySource, MenuItem, EntityRelation, ProgramKey, ProjectView, ProjectViewBookmark, Camera, ProjectViewLegacyTile, AbstractApi, EntityAttribute, EntityAttachment, EntityAttachmentType, Session } from 'bruce-models';
|
|
2
2
|
import * as Cesium from 'cesium';
|
|
3
|
-
import { Cartographic, Cartesian2, Math as Math$1, Cartesian3, CallbackProperty, Color, HeightReference, Rectangle,
|
|
3
|
+
import { Cartographic, Cartesian2, Math as Math$1, Cartesian3, CallbackProperty, Color, HeightReference, Rectangle, Entity, DistanceDisplayCondition, JulianDate, ClassificationType, ArcType, CornerType, ShadowMode, ConstantProperty, ConstantPositionProperty, HorizontalOrigin, VerticalOrigin, PolygonHierarchy, PolylineGraphics, ColorMaterialProperty, ColorBlendMode, HeadingPitchRoll, Transforms, Model, SceneMode, Primitive, Cesium3DTileFeature, GeoJsonDataSource, Cesium3DTileColorBlendMode, HeadingPitchRange, Cesium3DTileStyle, Ion, KmlDataSource, SceneTransforms, OrthographicFrustum, EasingFunction, NearFarScalar, EllipsoidTerrainProvider, BingMapsImageryProvider, BingMapsStyle, MapboxImageryProvider, MapboxStyleImageryProvider, ArcGisMapServerImageryProvider, OpenStreetMapImageryProvider, UrlTemplateImageryProvider, GridImageryProvider, GeographicTilingScheme, ImageryLayer, TileMapServiceImageryProvider, IonImageryProvider, CesiumTerrainProvider, CesiumInspector, defined, ClockRange, Cesium3DTileset, Matrix4, Matrix3, IonResource, EllipsoidGeodesic, sampleTerrainMostDetailed, PolygonPipeline, Quaternion, ModelGraphics, PolygonGraphics, CorridorGraphics, PointGraphics, BillboardGraphics, EllipseGraphics, PolylineDashMaterialProperty, BoundingSphere, GeometryInstance, ScreenSpaceEventHandler, ScreenSpaceEventType, CzmlDataSource, Intersect, Fullscreen } from 'cesium';
|
|
4
4
|
|
|
5
5
|
/*! *****************************************************************************
|
|
6
6
|
Copyright (c) Microsoft Corporation. All rights reserved.
|
|
@@ -15015,12 +15015,13 @@ var TilesetRenderEngine;
|
|
|
15015
15015
|
}
|
|
15016
15016
|
TilesetRenderEngine.RenderLegacy = RenderLegacy;
|
|
15017
15017
|
var Styler = /** @class */ (function () {
|
|
15018
|
-
function Styler(viewer, api, cTileset, fallbackStyleId, styleMapping, menuItemId, register) {
|
|
15018
|
+
function Styler(viewer, api, cTileset, fallbackStyleId, styleMapping, expandSources, menuItemId, register) {
|
|
15019
15019
|
var _a;
|
|
15020
15020
|
this.disposed = false;
|
|
15021
15021
|
this.styleMappingLoaded = false;
|
|
15022
15022
|
this.styleMappingsLoaded = {};
|
|
15023
15023
|
this.fallbackStyle = null;
|
|
15024
|
+
this.expandSources = false;
|
|
15024
15025
|
this.loadingCounter = 0;
|
|
15025
15026
|
// Dictionary of Entity ID -> boolean to indicate which Entities have been styled.
|
|
15026
15027
|
// This is used to determine if the Style colour needs to be overriden or not.
|
|
@@ -15031,6 +15032,7 @@ var TilesetRenderEngine;
|
|
|
15031
15032
|
this.viewer = viewer;
|
|
15032
15033
|
this.api = api;
|
|
15033
15034
|
this.cTileset = cTileset;
|
|
15035
|
+
this.expandSources = expandSources;
|
|
15034
15036
|
this.fallbackStyleId = fallbackStyleId;
|
|
15035
15037
|
this.styleMapping = styleMapping;
|
|
15036
15038
|
if (styleMapping) {
|
|
@@ -15091,6 +15093,9 @@ var TilesetRenderEngine;
|
|
|
15091
15093
|
else {
|
|
15092
15094
|
this.fallbackStyle = null;
|
|
15093
15095
|
}
|
|
15096
|
+
if (params.expandSources != null) {
|
|
15097
|
+
this.expandSources = params.expandSources;
|
|
15098
|
+
}
|
|
15094
15099
|
// Empty queues.
|
|
15095
15100
|
// Requeue all.
|
|
15096
15101
|
this.recordLoadQueue = [];
|
|
@@ -15150,7 +15155,8 @@ var TilesetRenderEngine;
|
|
|
15150
15155
|
return [4 /*yield*/, Entity$1.GetListByIds({
|
|
15151
15156
|
api: this.api,
|
|
15152
15157
|
entityIds: batch,
|
|
15153
|
-
migrated: true
|
|
15158
|
+
migrated: true,
|
|
15159
|
+
expandSources: this.expandSources
|
|
15154
15160
|
})];
|
|
15155
15161
|
case 2:
|
|
15156
15162
|
entities = (_c.sent()).entities;
|
|
@@ -15211,7 +15217,7 @@ var TilesetRenderEngine;
|
|
|
15211
15217
|
});
|
|
15212
15218
|
};
|
|
15213
15219
|
Styler.prototype.getEntityIdsForQueue = function () {
|
|
15214
|
-
var BATCH_SIZE = 500;
|
|
15220
|
+
var BATCH_SIZE = this.expandSources ? 200 : 500;
|
|
15215
15221
|
return this.recordLoadQueue.splice(0, BATCH_SIZE);
|
|
15216
15222
|
};
|
|
15217
15223
|
Styler.prototype.getEntityRego = function (entityId) {
|
|
@@ -15740,12 +15746,13 @@ var TilesetCadRenderManager;
|
|
|
15740
15746
|
}
|
|
15741
15747
|
this.viewer.scene.requestRender();
|
|
15742
15748
|
TilesetRenderEngine.OnTilesetReady(this.cTileset).then(function () {
|
|
15749
|
+
var _a;
|
|
15743
15750
|
try {
|
|
15744
15751
|
if (_this.disposed || cTileset.isDestroyed()) {
|
|
15745
15752
|
return;
|
|
15746
15753
|
}
|
|
15747
15754
|
_this.onCTilesetLoad();
|
|
15748
|
-
_this.styler = new TilesetRenderEngine.Styler(_this.viewer, api, _this.cTileset, _this.item.styleId, _this.item.StyleMapping, _this.item.id, _this.visualsManager);
|
|
15755
|
+
_this.styler = new TilesetRenderEngine.Styler(_this.viewer, api, _this.cTileset, _this.item.styleId, _this.item.StyleMapping, (_a = _this.item.BruceEntity) === null || _a === void 0 ? void 0 : _a.ExpandSources, _this.item.id, _this.visualsManager);
|
|
15749
15756
|
_this.viewer.scene.requestRender();
|
|
15750
15757
|
}
|
|
15751
15758
|
catch (e) {
|
|
@@ -16582,6 +16589,10 @@ var EntityFilterGetter;
|
|
|
16582
16589
|
},
|
|
16583
16590
|
viaCdn: this.viaCdn,
|
|
16584
16591
|
migrated: true,
|
|
16592
|
+
// If we're taking 5+ minutes to make a query, it's a dud.
|
|
16593
|
+
// This is a timeout imposed on our DB and not external sources.
|
|
16594
|
+
// Honestly could lower down to 30 seconds, but we'll keep it high for now.
|
|
16595
|
+
maxSearchTimeSec: 60 * 5,
|
|
16585
16596
|
req: {
|
|
16586
16597
|
// If we are passing in an abort, we MUST pass in noCache.
|
|
16587
16598
|
// Otherwise we will cache an aborted request.
|
|
@@ -16764,6 +16775,10 @@ var EntityFilterGetter;
|
|
|
16764
16775
|
},
|
|
16765
16776
|
viaCdn: this.viaCdn,
|
|
16766
16777
|
migrated: true,
|
|
16778
|
+
// If we're taking 5+ minutes to make a query, it's a dud.
|
|
16779
|
+
// This is a timeout imposed on our DB and not external sources.
|
|
16780
|
+
// Honestly could lower down to 30 seconds, but we'll keep it high for now.
|
|
16781
|
+
maxSearchTimeSec: 60 * 5,
|
|
16767
16782
|
req: {
|
|
16768
16783
|
// If we are passing in an abort, we MUST pass in noCache.
|
|
16769
16784
|
// Otherwise we will cache an aborted request.
|
|
@@ -17596,7 +17611,7 @@ var TilesetEntitiesRenderManager;
|
|
|
17596
17611
|
}
|
|
17597
17612
|
if (_this.item.ApplyStyles) {
|
|
17598
17613
|
var api_1 = _this.getters.GetBruceApi();
|
|
17599
|
-
_this.styler = new TilesetRenderEngine.Styler(_this.viewer, api_1, _this.cTileset, +_this.item.styleId, [], _this.item.id, _this.visualsManager);
|
|
17614
|
+
_this.styler = new TilesetRenderEngine.Styler(_this.viewer, api_1, _this.cTileset, +_this.item.styleId, [], false, _this.item.id, _this.visualsManager);
|
|
17600
17615
|
}
|
|
17601
17616
|
_this.onCTilesetLoad();
|
|
17602
17617
|
_this.viewer.scene.requestRender();
|
|
@@ -18265,7 +18280,7 @@ var TilesetArbRenderManager;
|
|
|
18265
18280
|
if (_this.item.ApplyStyles ||
|
|
18266
18281
|
_this.item.Type == MenuItem.EType.IonTileset) {
|
|
18267
18282
|
var api = _this.getters.GetBruceApi();
|
|
18268
|
-
_this.styler = new TilesetRenderEngine.Styler(_this.viewer, api, _this.cTileset, _this.item.styleId, _this.item.StyleMapping, _this.item.id, _this.visualsManager);
|
|
18283
|
+
_this.styler = new TilesetRenderEngine.Styler(_this.viewer, api, _this.cTileset, _this.item.styleId, _this.item.StyleMapping, false, _this.item.id, _this.visualsManager);
|
|
18269
18284
|
}
|
|
18270
18285
|
_this.onCTilesetLoad();
|
|
18271
18286
|
_this.viewer.scene.requestRender();
|
|
@@ -25956,7 +25971,7 @@ var MARKER_ICON_SVG = "\n <svg width=\"20\" height=\"20\" viewBox=\"0 0 24 24
|
|
|
25956
25971
|
var CLOSE_ICON_SVG = "\n <svg width=\"15\" height=\"15\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\">\n <path d=\"M15.7909 12L21.4767 6.3142C22.1744 5.61648 22.1744 4.48523 21.4767 3.78693L20.2131 2.5233C19.5153 1.82557 18.3841 1.82557 17.6858 2.5233L12 8.20909L6.3142 2.5233C5.61648 1.82557 4.48523 1.82557 3.78693 2.5233L2.5233 3.78693C1.82557 4.48466 1.82557 5.61591 2.5233 6.3142L8.20909 12L2.5233 17.6858C1.82557 18.3835 1.82557 19.5148 2.5233 20.2131L3.78693 21.4767C4.48466 22.1744 5.61648 22.1744 6.3142 21.4767L12 15.7909L17.6858 21.4767C18.3835 22.1744 19.5153 22.1744 20.2131 21.4767L21.4767 20.2131C22.1744 19.5153 22.1744 18.3841 21.4767 17.6858L15.7909 12Z\" fill=\"black\"/>\n </svg>\n";
|
|
25957
25972
|
function generateEle() {
|
|
25958
25973
|
var ele = document.createElement("div");
|
|
25959
|
-
ele.setAttribute("style", "\n left: 0px;\n top: 0px;\n position: absolute;\n z-index: 3;\n border-radius: 18px;\n background-color: white;\n display: flex;\n align-items: center;\n padding: 3px 4px;\n padding-right: 10px;\n font-size: 15px;\n pointer-events: none;\n box-shadow: 0px 0px 1px rgba(18, 22, 25, 0.24), 0px 18px 36px -4px rgba(18, 22, 25, 0.6);\n ");
|
|
25974
|
+
ele.setAttribute("style", "\n left: 0px;\n top: 0px;\n position: absolute;\n z-index: 3;\n border-radius: 18px;\n background-color: white;\n display: flex;\n align-items: center;\n padding: 3px 4px;\n padding-right: 10px;\n font-size: 15px;\n pointer-events: none;\n box-shadow: 0px 0px 1px rgba(18, 22, 25, 0.24), 0px 18px 36px -4px rgba(18, 22, 25, 0.6);\n color: black;\n ");
|
|
25960
25975
|
var icon = document.createElement("div");
|
|
25961
25976
|
icon.innerHTML = MARKER_ICON_SVG;
|
|
25962
25977
|
icon.setAttribute("style", "\n margin-right: 2px;\n height: 30px;\n width: 30px;\n display: flex;\n align-items: center;\n justify-content: center;\n ");
|
|
@@ -28217,7 +28232,7 @@ var WidgetViewBar = /** @class */ (function (_super) {
|
|
|
28217
28232
|
return WidgetViewBar;
|
|
28218
28233
|
}(Widget.AWidget));
|
|
28219
28234
|
|
|
28220
|
-
var VERSION = "4.
|
|
28235
|
+
var VERSION = "4.7.0";
|
|
28221
28236
|
|
|
28222
28237
|
export { VERSION, CesiumViewMonitor, ViewerUtils, ViewerEventTracker, MenuItemManager, EntityRenderEngine, EntityRenderEnginePoint, EntityRenderEnginePolyline, EntityRenderEnginePolygon, EntityRenderEngineModel3d, MenuItemCreator, VisualsRegister, RenderManager, EntitiesIdsRenderManager, EntitiesLoadedRenderManager, EntitiesRenderManager, EntityRenderManager, TilesetCadRenderManager, TilesetArbRenderManager, TilesetEntitiesRenderManager, TilesetOsmRenderManager, TilesetPointcloudRenderManager, TilesetGooglePhotosRenderManager, DataSourceStaticKmlManager, GoogleSearchRenderManager, RelationsRenderManager, SharedGetters, CesiumParabola, EntityLabel, ViewRenderEngine, TileRenderEngine, TilesetRenderEngine, CESIUM_INSPECTOR_KEY, CESIUM_TIMELINE_KEY, ViewUtils, DrawingUtils, MeasureUtils, EntityUtils, CesiumEntityStyler, CesiumAnimatedProperty, CesiumAnimatedInOut, Draw3dPolygon, Draw3dPolyline, MeasureCreator, Widget, VIEWER_BOOKMARKS_WIDGET_KEY, WidgetBookmarks, WidgetBranding, WidgetCursorBar, WidgetEmbeddedInfoView, WidgetInfoView, WidgetNavCompass$$1 as WidgetNavCompass, VIEWER_VIEW_BAR_WIDGET_KEY, WidgetViewBar, WidgetControlViewBar, WidgetControlViewBarSearch, VIEWER_LEFT_PANEL_WIDGET_KEY, VIEWER_LEFT_PANEL_CSS_VAR_LEFT, WidgetLeftPanel, WidgetLeftPanelTab, WidgetLeftPanelTabBookmarks };
|
|
28223
28238
|
//# sourceMappingURL=bruce-cesium.es5.js.map
|