bruce-cesium 2.5.8 → 2.6.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 +20 -10
- package/dist/bruce-cesium.es5.js.map +1 -1
- package/dist/bruce-cesium.umd.js +19 -9
- package/dist/bruce-cesium.umd.js.map +1 -1
- package/dist/lib/bruce-cesium.js +1 -1
- package/dist/lib/rendering/entity-render-engine.js +16 -6
- package/dist/lib/rendering/entity-render-engine.js.map +1 -1
- package/dist/lib/rendering/tileset-render-engine.js +2 -2
- package/dist/lib/rendering/tileset-render-engine.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,
|
|
3
|
+
import { Cartographic, Cartesian2, CallbackProperty, Cartesian3, Color, Rectangle, Math as Math$1, JulianDate, HeightReference, DistanceDisplayCondition, NearFarScalar, Entity, HorizontalOrigin, VerticalOrigin, ClassificationType, ArcType, CornerType, ShadowMode, PolygonHierarchy, HeadingPitchRoll, Transforms, ColorBlendMode, SceneMode, Cesium3DTileColorBlendMode, HeadingPitchRange, createOsmBuildings, Cesium3DTileStyle, Primitive, Cesium3DTileFeature, KmlDataSource, OrthographicFrustum, createWorldTerrain, EllipsoidTerrainProvider, CesiumTerrainProvider, BingMapsImageryProvider, BingMapsStyle, MapboxImageryProvider, MapboxStyleImageryProvider, ArcGisMapServerImageryProvider, OpenStreetMapImageryProvider, GridImageryProvider, GeographicTilingScheme, ImageryLayer, UrlTemplateImageryProvider, TileMapServiceImageryProvider, IonImageryProvider, Cesium3DTileset, Matrix4, Matrix3, IonResource, PolygonPipeline, CesiumInspector, defined, EllipsoidGeodesic, sampleTerrainMostDetailed, Model, ColorMaterialProperty, EasingFunction, GeometryInstance, ScreenSpaceEventHandler, ScreenSpaceEventType, Ion, BoundingSphere } from 'cesium';
|
|
4
4
|
|
|
5
5
|
var TIME_LAG = 300;
|
|
6
6
|
var POSITION_CHECK_TIMER = 950;
|
|
@@ -2114,7 +2114,7 @@ var EntityRenderEngine;
|
|
|
2114
2114
|
(function (Point) {
|
|
2115
2115
|
function Render(params) {
|
|
2116
2116
|
return __awaiter(this, void 0, void 0, function () {
|
|
2117
|
-
var entity, style, type, cEntity, siblings, iconUrlRows, icon, iconUrl, res, e_4, iconScale, heightRef, radius, bFill, cFill, outline, cOutline, outlineWidth, outlineHeight, bOutline, fillHeight, exHeightRef, pos, bColor, cColor, size, heightRef;
|
|
2117
|
+
var entity, style, type, cEntity, siblings, iconUrlRows, icon, iconUrl, res, e_4, iconScale, disableDepthTest, heightRef, radius, bFill, cFill, outline, cOutline, outlineWidth, outlineHeight, bOutline, fillHeight, exHeightRef, pos, bColor, cColor, size, heightRef;
|
|
2118
2118
|
return __generator(this, function (_a) {
|
|
2119
2119
|
switch (_a.label) {
|
|
2120
2120
|
case 0:
|
|
@@ -2176,6 +2176,7 @@ var EntityRenderEngine;
|
|
|
2176
2176
|
if (!iconScale && iconScale != 0) {
|
|
2177
2177
|
iconScale = 1;
|
|
2178
2178
|
}
|
|
2179
|
+
disableDepthTest = Boolean(style.renderOnTop);
|
|
2179
2180
|
if (iconScale > 0) {
|
|
2180
2181
|
heightRef = getHeightRef(style);
|
|
2181
2182
|
cEntity = new Entity({
|
|
@@ -2185,6 +2186,7 @@ var EntityRenderEngine;
|
|
|
2185
2186
|
image: iconUrl,
|
|
2186
2187
|
heightReference: getHeightRef(style),
|
|
2187
2188
|
scale: iconScale,
|
|
2189
|
+
disableDepthTestDistance: disableDepthTest ? Number.POSITIVE_INFINITY : undefined,
|
|
2188
2190
|
distanceDisplayCondition: getDisplayCondition(params.minDistance, params.maxDistance),
|
|
2189
2191
|
// Would be great once we have a setting for this.
|
|
2190
2192
|
// translucencyByDistance: getTranslucencyByDistance(params.minDistance, params.maxDistance),
|
|
@@ -2440,12 +2442,16 @@ var EntityRenderEngine;
|
|
|
2440
2442
|
if (units != "px" && units != "m") {
|
|
2441
2443
|
units = "px";
|
|
2442
2444
|
}
|
|
2445
|
+
var classification = ClassificationType.TERRAIN;
|
|
2446
|
+
if (style.drapeOver == "ALL") {
|
|
2447
|
+
classification = ClassificationType.BOTH;
|
|
2448
|
+
}
|
|
2443
2449
|
var cEntity = new Entity({
|
|
2444
2450
|
polyline: units == "px" ? {
|
|
2445
2451
|
positions: posses,
|
|
2446
2452
|
material: cColor,
|
|
2447
2453
|
width: width,
|
|
2448
|
-
classificationType:
|
|
2454
|
+
classificationType: classification,
|
|
2449
2455
|
arcType: ArcType.GEODESIC,
|
|
2450
2456
|
zIndex: getZIndex(style, entity, params.tags),
|
|
2451
2457
|
clampToGround: heightRef == HeightReference.CLAMP_TO_GROUND,
|
|
@@ -2455,7 +2461,7 @@ var EntityRenderEngine;
|
|
|
2455
2461
|
positions: posses,
|
|
2456
2462
|
material: cColor,
|
|
2457
2463
|
width: width,
|
|
2458
|
-
classificationType:
|
|
2464
|
+
classificationType: classification,
|
|
2459
2465
|
heightReference: heightRef,
|
|
2460
2466
|
zIndex: getZIndex(style, entity, params.tags),
|
|
2461
2467
|
distanceDisplayCondition: getDisplayCondition(params.minDistance, params.maxDistance, width),
|
|
@@ -2583,6 +2589,10 @@ var EntityRenderEngine;
|
|
|
2583
2589
|
});
|
|
2584
2590
|
var zIndex = getZIndex(style, entity, params.tags);
|
|
2585
2591
|
var size = getSizeOfPolygonEntity(entity);
|
|
2592
|
+
var classification = ClassificationType.TERRAIN;
|
|
2593
|
+
if (style.drapeOver == "ALL") {
|
|
2594
|
+
classification = ClassificationType.BOTH;
|
|
2595
|
+
}
|
|
2586
2596
|
var cEntity = new Entity({
|
|
2587
2597
|
polygon: {
|
|
2588
2598
|
hierarchy: new PolygonHierarchy(posses, holePosses.map(function (x) { return new PolygonHierarchy(x); })),
|
|
@@ -2591,7 +2601,7 @@ var EntityRenderEngine;
|
|
|
2591
2601
|
extrudedHeightReference: extrusion.exHeightRef,
|
|
2592
2602
|
shadows: ShadowMode.ENABLED,
|
|
2593
2603
|
heightReference: heightRef,
|
|
2594
|
-
classificationType:
|
|
2604
|
+
classificationType: classification,
|
|
2595
2605
|
perPositionHeight: heightRef == HeightReference.CLAMP_TO_GROUND ? false : true,
|
|
2596
2606
|
zIndex: zIndex,
|
|
2597
2607
|
distanceDisplayCondition: getDisplayCondition(params.minDistance, params.maxDistance, size, true)
|
|
@@ -2649,7 +2659,7 @@ var EntityRenderEngine;
|
|
|
2649
2659
|
fill: true,
|
|
2650
2660
|
zIndex: zIndex + 1,
|
|
2651
2661
|
cornerType: CornerType.MITERED,
|
|
2652
|
-
classificationType:
|
|
2662
|
+
classificationType: classification,
|
|
2653
2663
|
distanceDisplayCondition: getDisplayCondition(params.minDistance, params.maxDistance, width),
|
|
2654
2664
|
shadows: ShadowMode.ENABLED
|
|
2655
2665
|
},
|
|
@@ -2680,7 +2690,7 @@ var EntityRenderEngine;
|
|
|
2680
2690
|
fill: true,
|
|
2681
2691
|
zIndex: zIndex + 1,
|
|
2682
2692
|
cornerType: CornerType.MITERED,
|
|
2683
|
-
classificationType:
|
|
2693
|
+
classificationType: classification,
|
|
2684
2694
|
distanceDisplayCondition: getDisplayCondition(params.minDistance, params.maxDistance, width),
|
|
2685
2695
|
shadows: ShadowMode.ENABLED,
|
|
2686
2696
|
},
|
|
@@ -7196,7 +7206,7 @@ var TilesetRenderEngine;
|
|
|
7196
7206
|
* The maximum memory in MB that can be used by all tilesets.
|
|
7197
7207
|
* This is distributed evenly between all loaded tilesets.
|
|
7198
7208
|
*/
|
|
7199
|
-
TilesetRenderEngine.MAX_TILESET_MEMORY = 1024;
|
|
7209
|
+
TilesetRenderEngine.MAX_TILESET_MEMORY = 1024 * 4;
|
|
7200
7210
|
/**
|
|
7201
7211
|
* Watches tilesets in the viewer.
|
|
7202
7212
|
* This will regulate their max memory param.
|
|
@@ -7213,7 +7223,7 @@ var TilesetRenderEngine;
|
|
|
7213
7223
|
// We'll need to allow user to change this somehow.
|
|
7214
7224
|
var maxMemory = TilesetRenderEngine.MAX_TILESET_MEMORY;
|
|
7215
7225
|
// Minimum memory in MB per tileset.
|
|
7216
|
-
var minMemory =
|
|
7226
|
+
var minMemory = 200;
|
|
7217
7227
|
var totalPerTileset = Math.max(this.watched.length ? maxMemory / this.watched.length : maxMemory, minMemory);
|
|
7218
7228
|
this.watched.forEach(function (x) {
|
|
7219
7229
|
x.maximumMemoryUsage = totalPerTileset;
|
|
@@ -15010,7 +15020,7 @@ var ViewerUtils;
|
|
|
15010
15020
|
ViewerUtils.CreateWidgets = CreateWidgets;
|
|
15011
15021
|
})(ViewerUtils || (ViewerUtils = {}));
|
|
15012
15022
|
|
|
15013
|
-
var VERSION$1 = "2.
|
|
15023
|
+
var VERSION$1 = "2.6.0";
|
|
15014
15024
|
|
|
15015
15025
|
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, ViewRenderEngine, TileRenderEngine, TilesetRenderEngine, CESIUM_INSPECTOR_KEY, ViewUtils, DrawingUtils, MeasureUtils, EntityUtils, Draw3dPolygon, Draw3dPolyline };
|
|
15016
15026
|
//# sourceMappingURL=bruce-cesium.es5.js.map
|