bruce-cesium 2.4.0 → 2.4.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.
@@ -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, DelayQueue, BatchedDataGetter, EntityRelationType, 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, SceneMode, Entity, Primitive, Cesium3DTileFeature, HeightReference, DistanceDisplayCondition, NearFarScalar, HorizontalOrigin, VerticalOrigin, ClassificationType, ArcType, PolygonHierarchy, ShadowMode, PolylineGraphics, HeadingPitchRoll, Transforms, ColorBlendMode, Cesium3DTileColorBlendMode, HeadingPitchRange, createOsmBuildings, Cesium3DTileStyle, KmlDataSource, OrthographicFrustum, JulianDate, createWorldTerrain, EllipsoidTerrainProvider, CesiumTerrainProvider, BingMapsImageryProvider, BingMapsStyle, MapboxImageryProvider, MapboxStyleImageryProvider, ArcGisMapServerImageryProvider, OpenStreetMapImageryProvider, GridImageryProvider, GeographicTilingScheme, ImageryLayer, UrlTemplateImageryProvider, TileMapServiceImageryProvider, IonImageryProvider, Cesium3DTileset, Matrix4, Matrix3, IonResource, EllipsoidGeodesic, sampleTerrainMostDetailed, defined, Model, CesiumInspector, PolygonPipeline, ColorMaterialProperty, EasingFunction, GeometryInstance, ScreenSpaceEventHandler, ScreenSpaceEventType, Ion, BoundingSphere } from 'cesium';
3
+ import { Cartographic, Cartesian2, CallbackProperty, Cartesian3, Color, Rectangle, Math as Math$1, HeightReference, DistanceDisplayCondition, NearFarScalar, Entity, HorizontalOrigin, VerticalOrigin, ClassificationType, ArcType, PolygonHierarchy, ShadowMode, HeadingPitchRoll, Transforms, ColorBlendMode, Primitive, Cesium3DTileFeature, SceneMode, HeadingPitchRange, Cesium3DTileColorBlendMode, createOsmBuildings, Cesium3DTileStyle, KmlDataSource, OrthographicFrustum, JulianDate, Cesium3DTileset, Matrix4, Matrix3, IonResource, EllipsoidGeodesic, EllipsoidTerrainProvider, sampleTerrainMostDetailed, defined, Model, PolygonPipeline, createWorldTerrain, CesiumTerrainProvider, BingMapsImageryProvider, BingMapsStyle, MapboxImageryProvider, MapboxStyleImageryProvider, ArcGisMapServerImageryProvider, OpenStreetMapImageryProvider, GridImageryProvider, GeographicTilingScheme, ImageryLayer, UrlTemplateImageryProvider, TileMapServiceImageryProvider, IonImageryProvider, ScreenSpaceEventHandler, ScreenSpaceEventType, CesiumInspector, ColorMaterialProperty, EasingFunction, GeometryInstance, Ion, BoundingSphere } from 'cesium';
4
4
 
5
5
  var TIME_LAG = 300;
6
6
  var POSITION_CHECK_TIMER = 950;
@@ -823,6 +823,8 @@ function revertAppliedEntityOpacity(viewer, entity) {
823
823
  processKey("point", "color");
824
824
  processKey("ellipse");
825
825
  processKey("model", "color");
826
+ processKey("corridor");
827
+ processKey("billboard", "color");
826
828
  }
827
829
  else if (entity instanceof Cesium3DTileFeature) {
828
830
  var orgOpacity = entity[ORG_OPACITY_KEY];
@@ -859,6 +861,8 @@ function applyOpacityToEntity(viewer, opacity, entity) {
859
861
  processKey("point", "color");
860
862
  processKey("ellipse");
861
863
  processKey("model", "color");
864
+ processKey("corridor");
865
+ processKey("billboard", "color");
862
866
  }
863
867
  else if (entity instanceof Cesium3DTileFeature) {
864
868
  var orgOpacity = entity[ORG_OPACITY_KEY];
@@ -919,6 +923,9 @@ var EntityUtils;
919
923
  else if (visual.billboard) {
920
924
  visualHeightRef = GetValue(viewer, visual.billboard.heightReference);
921
925
  }
926
+ else if (visual.corridor) {
927
+ visualHeightRef = GetValue(viewer, visual.corridor.heightReference);
928
+ }
922
929
  else if (visual.ellipse) {
923
930
  visualHeightRef = GetValue(viewer, visual.ellipse.heightReference);
924
931
  }
@@ -2484,16 +2491,27 @@ var EntityRenderEngine;
2484
2491
  Cartes.CloseRing3(borderPosses);
2485
2492
  }
2486
2493
  var cEntityBorder = new Entity({
2487
- polyline: new PolylineGraphics({
2494
+ // polyline: new Cesium.PolylineGraphics({
2495
+ // positions: borderPosses,
2496
+ // material: <Cesium.MaterialProperty><any>cLineColor,
2497
+ // width: width,
2498
+ // clampToGround: heightRef == Cesium.HeightReference.CLAMP_TO_GROUND,
2499
+ // classificationType: Cesium.ClassificationType.TERRAIN,
2500
+ // arcType: Cesium.ArcType.GEODESIC,
2501
+ // zIndex: zIndex,
2502
+ // distanceDisplayCondition: getDisplayCondition(params.minDistance, params.maxDistance)
2503
+ // }),
2504
+ corridor: {
2488
2505
  positions: borderPosses,
2489
2506
  material: cLineColor,
2507
+ heightReference: heightRef,
2490
2508
  width: width,
2491
- clampToGround: heightRef == HeightReference.CLAMP_TO_GROUND,
2492
- classificationType: ClassificationType.TERRAIN,
2493
- arcType: ArcType.GEODESIC,
2509
+ fill: true,
2494
2510
  zIndex: zIndex,
2495
- distanceDisplayCondition: getDisplayCondition(params.minDistance, params.maxDistance)
2496
- }),
2511
+ classificationType: ClassificationType.TERRAIN,
2512
+ distanceDisplayCondition: getDisplayCondition(params.minDistance, params.maxDistance),
2513
+ shadows: ShadowMode.ENABLED
2514
+ },
2497
2515
  show: false
2498
2516
  });
2499
2517
  params.viewer.entities.add(cEntityBorder);
@@ -2503,16 +2521,27 @@ var EntityRenderEngine;
2503
2521
  var posses_1 = holePosses[i];
2504
2522
  Cartes.CloseRing3(posses_1);
2505
2523
  var cEntityHole = new Entity({
2506
- polyline: new PolylineGraphics({
2507
- positions: posses_1,
2524
+ // polyline: new Cesium.PolylineGraphics({
2525
+ // positions: posses,
2526
+ // material: <Cesium.MaterialProperty><any>cLineColor,
2527
+ // width: width,
2528
+ // clampToGround: heightRef == Cesium.HeightReference.CLAMP_TO_GROUND,
2529
+ // classificationType: Cesium.ClassificationType.TERRAIN,
2530
+ // arcType: Cesium.ArcType.GEODESIC,
2531
+ // zIndex: zIndex,
2532
+ // distanceDisplayCondition: getDisplayCondition(params.minDistance, params.maxDistance)
2533
+ // }),
2534
+ corridor: {
2535
+ positions: borderPosses,
2508
2536
  material: cLineColor,
2537
+ heightReference: heightRef,
2509
2538
  width: width,
2510
- clampToGround: heightRef == HeightReference.CLAMP_TO_GROUND,
2511
- classificationType: ClassificationType.TERRAIN,
2512
- arcType: ArcType.GEODESIC,
2539
+ fill: true,
2513
2540
  zIndex: zIndex,
2514
- distanceDisplayCondition: getDisplayCondition(params.minDistance, params.maxDistance)
2515
- }),
2541
+ classificationType: ClassificationType.TERRAIN,
2542
+ distanceDisplayCondition: getDisplayCondition(params.minDistance, params.maxDistance),
2543
+ shadows: ShadowMode.ENABLED
2544
+ },
2516
2545
  show: false
2517
2546
  });
2518
2547
  cEntity._siblingGraphics.push(cEntityHole);
@@ -4930,6 +4959,7 @@ function select(viewer, visual, color) {
4930
4959
  "polyline": "material",
4931
4960
  "model": "color",
4932
4961
  "billboard": "color",
4962
+ "corridor": "material",
4933
4963
  "ellipse": "material"
4934
4964
  };
4935
4965
  var _loop_1 = function (i) {
@@ -4989,6 +5019,7 @@ function deselect(viewer, visual) {
4989
5019
  "polyline": "material",
4990
5020
  "model": "color",
4991
5021
  "billboard": "color",
5022
+ "corridor": "material",
4992
5023
  "ellipse": "material"
4993
5024
  };
4994
5025
  var _loop_2 = function (i) {
@@ -14399,7 +14430,7 @@ var ViewerUtils;
14399
14430
  ViewerUtils.CreateWidgets = CreateWidgets;
14400
14431
  })(ViewerUtils || (ViewerUtils = {}));
14401
14432
 
14402
- var VERSION$1 = "2.4.0";
14433
+ var VERSION$1 = "2.4.1";
14403
14434
 
14404
14435
  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 };
14405
14436
  //# sourceMappingURL=bruce-cesium.es5.js.map