bruce-cesium 7.7.6 → 7.7.7
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 +24 -3
- package/dist/bruce-cesium.es5.js.map +1 -1
- package/dist/bruce-cesium.umd.js +22 -1
- package/dist/bruce-cesium.umd.js.map +1 -1
- package/dist/lib/bruce-cesium.js +1 -1
- package/dist/lib/rendering/entity-render-engine-polygon.js +21 -0
- package/dist/lib/rendering/entity-render-engine-polygon.js.map +1 -1
- package/dist/types/bruce-cesium.d.ts +1 -1
- package/package.json +1 -1
package/dist/bruce-cesium.es5.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as Cesium from 'cesium';
|
|
2
|
-
import { Cartographic, ColorMaterialProperty, Entity, Color, ConstantProperty, CallbackProperty, Primitive, Cesium3DTileFeature,
|
|
3
|
-
import { Cartes, LRUCache, Carto, ProjectViewTile, EntityHistoricData, BruceEvent, DelayQueue, Entity as Entity$1, EntityTag, ClientFile, ENVIRONMENT, EntityAttachmentType, EntityRelationType, EntityType, Tileset, Calculator, DataLab, Style, ObjectUtils, MenuItem, AccountConcept, RecordChangeFeed, EntityLod, UrlUtils,
|
|
2
|
+
import { Cartographic, ColorMaterialProperty, Entity, Color, ConstantProperty, CallbackProperty, Primitive, Cesium3DTileFeature, ShaderSource, Cartesian3, Math as Math$1, Ellipsoid, Transforms, Matrix4, Geometry, GeometryAttribute, ComponentDatatype, PrimitiveType, BoundingSphere, GeometryPipeline, Cartesian2, Cartesian4, sampleTerrain, Texture, PixelFormat, Sampler, TextureWrap, TextureMinificationFilter, TextureMagnificationFilter, PixelDatatype, VertexArray, BufferUsage, ShaderProgram, RenderState, BlendingState, DrawCommand, Pass, ConstantPositionProperty, HeightReference, DistanceDisplayCondition, JulianDate, Quaternion, HeadingPitchRoll, ColorBlendMode, ShadowMode, Model, ClassificationType, HorizontalOrigin, VerticalOrigin, ImageMaterialProperty, PolygonHierarchy, PolylineGraphics, ArcType, CornerType, Rectangle, SceneMode, IntersectionTests, Ray, SceneTransforms, FeatureDetection, Matrix3, NearFarScalar, KmlDataSource, GeoJsonDataSource, Cesium3DTileStyle, HeadingPitchRange, Cesium3DTileColorBlendMode, Ion, IonResource, Cesium3DTileset, EllipsoidTerrainProvider, IonImageryProvider, createWorldImagery, createWorldImageryAsync, BingMapsImageryProvider, BingMapsStyle, MapboxImageryProvider, MapboxStyleImageryProvider, ArcGisMapServerImageryProvider, OpenStreetMapImageryProvider, UrlTemplateImageryProvider, GridImageryProvider, GeographicTilingScheme, ImageryLayer, TileMapServiceImageryProvider, CesiumTerrainProvider, OrthographicFrustum, EasingFunction, Intersect, CustomDataSource, WebGLConstants, EllipsoidGeodesic, sampleTerrainMostDetailed, defined, ModelGraphics, PolygonGraphics, CorridorGraphics, PointGraphics, BillboardGraphics, EllipseGraphics, PolylineDashMaterialProperty, PolygonPipeline, CesiumInspector, ClockRange, DynamicEnvironmentMapManager, GeometryInstance, ScreenSpaceEventHandler, ScreenSpaceEventType, Fullscreen, CzmlDataSource } from 'cesium';
|
|
3
|
+
import { Cartes, LRUCache, Carto, ProjectViewTile, EntityHistoricData, BruceEvent, DelayQueue, Entity as Entity$1, EntityTag, ClientFile, ENVIRONMENT, EntityAttachmentType, EntityRelationType, EntityType, Tileset, Calculator, DataLab, Style, ObjectUtils, MenuItem, AccountConcept, RecordChangeFeed, EntityLod, UrlUtils, Api, Bounds, ClientFileValueMap, Color as Color$1, Geometry as Geometry$1, ProjectView, ProjectViewBookmark, ZoomControl, Assembly, EntityCoords, BruceApi, EntityRelation, EntitySource, ProgramKey, ProjectViewLegacyTile, Camera, Account, AccountLimits, Session, EntityAttachment, EntityAttribute, MathUtils, ProjectViewBookmarkGroup } from 'bruce-models';
|
|
4
4
|
|
|
5
5
|
/**
|
|
6
6
|
* Ensures a number is returned from a given value.
|
|
@@ -55007,6 +55007,12 @@ var EntityRenderEnginePolygon;
|
|
|
55007
55007
|
? Geometry$1.ParsePoints(ring.LinearRing).map((point) => point.altitude)
|
|
55008
55008
|
: [])
|
|
55009
55009
|
});
|
|
55010
|
+
const drapesOnGround = (heightRef === HeightReference.CLAMP_TO_GROUND &&
|
|
55011
|
+
extrusion.value == undefined &&
|
|
55012
|
+
!drawsDisplacedSurface);
|
|
55013
|
+
if (drapesOnGround) {
|
|
55014
|
+
posses = groundPosses(posses);
|
|
55015
|
+
}
|
|
55010
55016
|
posses = CullDuplicateCPosses(posses);
|
|
55011
55017
|
if (posses.length < 4) {
|
|
55012
55018
|
return null;
|
|
@@ -55015,6 +55021,9 @@ var EntityRenderEnginePolygon;
|
|
|
55015
55021
|
const holePosses = holeRings.map((x) => {
|
|
55016
55022
|
const points = Geometry$1.ParsePoints(x.LinearRing);
|
|
55017
55023
|
let holePosses = points.map(x => Cartesian3.fromDegrees(EnsureNumber(x.longitude), EnsureNumber(x.latitude), EnsureNumber(x.altitude)));
|
|
55024
|
+
if (drapesOnGround) {
|
|
55025
|
+
holePosses = groundPosses(holePosses);
|
|
55026
|
+
}
|
|
55018
55027
|
holePosses = CullDuplicateCPosses(holePosses);
|
|
55019
55028
|
Cartes.CloseRing3(holePosses);
|
|
55020
55029
|
return holePosses;
|
|
@@ -55801,6 +55810,18 @@ function waterFor(style) {
|
|
|
55801
55810
|
/*
|
|
55802
55811
|
* The lon/lat bounding rectangle of a ring, which is the frame Cesium drapes an image material in.
|
|
55803
55812
|
*/
|
|
55813
|
+
/*
|
|
55814
|
+
* Moves a ring onto the ellipsoid, as Cesium fills only a strip of a ground polygon with high vertices.
|
|
55815
|
+
*/
|
|
55816
|
+
function groundPosses(posses) {
|
|
55817
|
+
return posses.map((pos) => {
|
|
55818
|
+
const carto = Cartographic.fromCartesian(pos);
|
|
55819
|
+
if (!carto) {
|
|
55820
|
+
return pos;
|
|
55821
|
+
}
|
|
55822
|
+
return Cartesian3.fromRadians(carto.longitude, carto.latitude, 0);
|
|
55823
|
+
});
|
|
55824
|
+
}
|
|
55804
55825
|
function polygonBbox(posses) {
|
|
55805
55826
|
if (!posses || posses.length === 0) {
|
|
55806
55827
|
return undefined;
|
|
@@ -57727,7 +57748,7 @@ var StyleUtils;
|
|
|
57727
57748
|
StyleUtils.ApplyTypeStyle = ApplyTypeStyle;
|
|
57728
57749
|
})(StyleUtils || (StyleUtils = {}));
|
|
57729
57750
|
|
|
57730
|
-
const VERSION = "7.7.
|
|
57751
|
+
const VERSION = "7.7.7";
|
|
57731
57752
|
/**
|
|
57732
57753
|
* Updates the environment instance used by bruce-cesium to one specified.
|
|
57733
57754
|
* This can be used to ensure that the instance a parent is referencing is shared between bruce-cesium, bruce-models, and the parent app.
|