bruce-cesium 7.3.7 → 7.3.8

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.
Files changed (24) hide show
  1. package/dist/bruce-cesium.es5.js +119 -30
  2. package/dist/bruce-cesium.es5.js.map +1 -1
  3. package/dist/bruce-cesium.umd.js +117 -28
  4. package/dist/bruce-cesium.umd.js.map +1 -1
  5. package/dist/lib/bruce-cesium.js +1 -1
  6. package/dist/lib/rendering/displaced-surface-primitive.js +63 -24
  7. package/dist/lib/rendering/displaced-surface-primitive.js.map +1 -1
  8. package/dist/lib/rendering/entity-render-engine.js +22 -0
  9. package/dist/lib/rendering/entity-render-engine.js.map +1 -1
  10. package/dist/lib/rendering/render-managers/entities/entities-datalab-render-manager.js +5 -0
  11. package/dist/lib/rendering/render-managers/entities/entities-datalab-render-manager.js.map +1 -1
  12. package/dist/lib/rendering/render-managers/entities/entities-ids-render-manager.js +8 -3
  13. package/dist/lib/rendering/render-managers/entities/entities-ids-render-manager.js.map +1 -1
  14. package/dist/lib/rendering/render-managers/entities/entities-loaded-render-manager.js +5 -0
  15. package/dist/lib/rendering/render-managers/entities/entities-loaded-render-manager.js.map +1 -1
  16. package/dist/lib/rendering/render-managers/entities/entities-render-manager.js +5 -0
  17. package/dist/lib/rendering/render-managers/entities/entities-render-manager.js.map +1 -1
  18. package/dist/lib/rendering/visuals-register.js +8 -0
  19. package/dist/lib/rendering/visuals-register.js.map +1 -1
  20. package/dist/types/bruce-cesium.d.ts +1 -1
  21. package/dist/types/rendering/displaced-surface-primitive.d.ts +4 -0
  22. package/dist/types/rendering/entity-render-engine.d.ts +9 -0
  23. package/dist/types/rendering/visuals-register.d.ts +5 -0
  24. package/package.json +1 -1
@@ -1,6 +1,6 @@
1
1
  import * as Cesium from 'cesium';
2
- import { Cartographic, ColorMaterialProperty, Entity, Color, ConstantProperty, CallbackProperty, Primitive, Cesium3DTileFeature, HeightReference, ColorBlendMode, HeadingPitchRoll, Math as Math$1, Transforms, ShadowMode, Cartesian3, ClassificationType, Model, JulianDate, Quaternion, Matrix4, ArcType, CornerType, ConstantPositionProperty, HorizontalOrigin, VerticalOrigin, ShaderSource, Ellipsoid, Geometry, GeometryAttribute, ComponentDatatype, PrimitiveType, BoundingSphere, GeometryPipeline, Cartesian2, sampleTerrain, Texture, PixelFormat, Sampler, TextureWrap, TextureMinificationFilter, TextureMagnificationFilter, Cartesian4, VertexArray, BufferUsage, ShaderProgram, RenderState, BlendingState, DrawCommand, Pass, DistanceDisplayCondition, ImageMaterialProperty, SceneTransforms, PolygonHierarchy, PolylineGraphics, Rectangle, NearFarScalar, Matrix3, KmlDataSource, GeoJsonDataSource, SceneMode, Cesium3DTileStyle, Cesium3DTileColorBlendMode, HeadingPitchRange, Ion, IonResource, OrthographicFrustum, EasingFunction, Cesium3DTileset, EllipsoidTerrainProvider, IonImageryProvider, createWorldImagery, createWorldImageryAsync, BingMapsImageryProvider, BingMapsStyle, MapboxImageryProvider, MapboxStyleImageryProvider, ArcGisMapServerImageryProvider, OpenStreetMapImageryProvider, UrlTemplateImageryProvider, GridImageryProvider, GeographicTilingScheme, ImageryLayer, TileMapServiceImageryProvider, CesiumTerrainProvider, ModelGraphics, PolygonGraphics, CorridorGraphics, PointGraphics, BillboardGraphics, EllipseGraphics, PolylineDashMaterialProperty, Intersect, PolygonPipeline, EllipsoidGeodesic, sampleTerrainMostDetailed, defined, CesiumInspector, ClockRange, DynamicEnvironmentMapManager, GeometryInstance, CustomDataSource, ScreenSpaceEventHandler, ScreenSpaceEventType, Fullscreen, CzmlDataSource } from 'cesium';
3
- import { Cartes, LRUCache, ProjectViewTile, ENVIRONMENT, Calculator, ClientFile, Entity as Entity$1, EntityLod, EntityTag, EntityType, ObjectUtils, Style, Carto, Geometry as Geometry$1, Api, ClientFileValueMap, Color as Color$1, Bounds, MenuItem, ProjectView, ProjectViewBookmark, Tileset, ZoomControl, BruceEvent, EntityCoords, DataLab, DelayQueue, AccountConcept, BruceApi, EntityRelation, EntitySource, RecordChangeFeed, Camera, ProgramKey, ProjectViewLegacyTile, Account, AccountLimits, Session, UrlUtils, ProjectViewBookmarkGroup, EntityAttachment, EntityAttachmentType, EntityAttribute, MathUtils, EntityRelationType, EntityHistoricData } from 'bruce-models';
2
+ import { Cartographic, ColorMaterialProperty, Entity, Color, ConstantProperty, CallbackProperty, Primitive, Cesium3DTileFeature, HeightReference, DistanceDisplayCondition, ShaderSource, Cartesian3, Math as Math$1, Ellipsoid, Transforms, Matrix4, Geometry, GeometryAttribute, ComponentDatatype, PrimitiveType, BoundingSphere, GeometryPipeline, Cartesian2, Cartesian4, sampleTerrain, Texture, PixelFormat, Sampler, TextureWrap, TextureMinificationFilter, TextureMagnificationFilter, VertexArray, BufferUsage, ShaderProgram, RenderState, BlendingState, DrawCommand, Pass, JulianDate, Quaternion, HeadingPitchRoll, ClassificationType, ArcType, CornerType, ShadowMode, ConstantPositionProperty, HorizontalOrigin, VerticalOrigin, ColorBlendMode, Model, ImageMaterialProperty, PolygonHierarchy, PolylineGraphics, Rectangle, SceneTransforms, NearFarScalar, Matrix3, KmlDataSource, GeoJsonDataSource, SceneMode, Cesium3DTileStyle, HeadingPitchRange, Ion, IonResource, Cesium3DTileColorBlendMode, Cesium3DTileset, EllipsoidTerrainProvider, IonImageryProvider, createWorldImagery, createWorldImageryAsync, BingMapsImageryProvider, BingMapsStyle, MapboxImageryProvider, MapboxStyleImageryProvider, ArcGisMapServerImageryProvider, OpenStreetMapImageryProvider, UrlTemplateImageryProvider, GridImageryProvider, GeographicTilingScheme, ImageryLayer, TileMapServiceImageryProvider, CesiumTerrainProvider, Intersect, OrthographicFrustum, EasingFunction, ModelGraphics, PolygonGraphics, CorridorGraphics, PointGraphics, BillboardGraphics, EllipseGraphics, PolylineDashMaterialProperty, PolygonPipeline, EllipsoidGeodesic, sampleTerrainMostDetailed, defined, CustomDataSource, CesiumInspector, ClockRange, DynamicEnvironmentMapManager, ScreenSpaceEventHandler, ScreenSpaceEventType, GeometryInstance, Fullscreen, CzmlDataSource } from 'cesium';
3
+ import { Cartes, LRUCache, ProjectViewTile, ENVIRONMENT, Calculator, Carto, Entity as Entity$1, EntityTag, EntityType, Geometry as Geometry$1, ObjectUtils, Style, Api, ClientFile, EntityLod, Bounds, ClientFileValueMap, Color as Color$1, MenuItem, ProjectView, ProjectViewBookmark, Tileset, ZoomControl, BruceEvent, EntityCoords, DataLab, DelayQueue, AccountConcept, RecordChangeFeed, EntityRelation, BruceApi, EntitySource, ProgramKey, ProjectViewLegacyTile, Camera, Account, AccountLimits, Session, UrlUtils, EntityAttachment, EntityAttachmentType, EntityAttribute, MathUtils, ProjectViewBookmarkGroup, EntityRelationType, EntityHistoricData } from 'bruce-models';
4
4
 
5
5
  /**
6
6
  * Ensures a number is returned from a given value.
@@ -9514,6 +9514,14 @@ var VisualsRegister;
9514
9514
  }
9515
9515
  };
9516
9516
  }
9517
+ /**
9518
+ * Whether this register is holding a record of a visual.
9519
+ * @param visual
9520
+ */
9521
+ HasRego(visual) {
9522
+ const vis = visual;
9523
+ return Boolean(vis && vis._register === this && vis._rego);
9524
+ }
9517
9525
  /**
9518
9526
  * Locates a visual corresponding to a given entity id.
9519
9527
  * If no menu item id is provided, then it will pick the "best" one.
@@ -12685,6 +12693,11 @@ var EntitiesRenderManager;
12685
12693
  optimizeTolerance: this.item.optimizeTolerance,
12686
12694
  });
12687
12695
  if (this.disposed) {
12696
+ EntityRenderEngine.RemoveAll({
12697
+ viewer: this.viewer,
12698
+ entities: cEntities,
12699
+ register: this.visualsManager
12700
+ });
12688
12701
  this.doDispose();
12689
12702
  return;
12690
12703
  }
@@ -13692,6 +13705,11 @@ var EntitiesLoadedRenderManager;
13692
13705
  force
13693
13706
  });
13694
13707
  if (this.disposed) {
13708
+ EntityRenderEngine.RemoveAll({
13709
+ viewer: this.viewer,
13710
+ entities: cEntities,
13711
+ register: this.visualsManager
13712
+ });
13695
13713
  this.visualsManager.RemoveRegos({
13696
13714
  menuItemId: this.item.id
13697
13715
  });
@@ -14136,10 +14154,15 @@ var EntitiesIdsRenderManager;
14136
14154
  zoomControl: this.item.CameraZoomSettings,
14137
14155
  force: force || changed
14138
14156
  });
14157
+ if (this.disposed) {
14158
+ EntityRenderEngine.RemoveAll({
14159
+ viewer: this.viewer,
14160
+ entities: cEntities,
14161
+ register: this.visualsManager
14162
+ });
14163
+ return;
14164
+ }
14139
14165
  for (let i = 0; i < entities.length; i++) {
14140
- if (this.disposed) {
14141
- break;
14142
- }
14143
14166
  const entity = entities[i];
14144
14167
  const id = entity.Bruce.ID;
14145
14168
  const cEntity = cEntities.get(id);
@@ -19520,6 +19543,11 @@ var DataLabRenderManager;
19520
19543
  force
19521
19544
  });
19522
19545
  if (this.disposed) {
19546
+ EntityRenderEngine.RemoveAll({
19547
+ viewer: this.viewer,
19548
+ entities: cEntities,
19549
+ register: this.visualsManager
19550
+ });
19523
19551
  return;
19524
19552
  }
19525
19553
  for (let i = 0; i < entities.length; i++) {
@@ -43668,17 +43696,21 @@ uniform vec2 u_maskGroundSize;
43668
43696
  uniform vec4 u_extentDegrees;
43669
43697
  uniform vec4 u_maskGroundDegrees;
43670
43698
  uniform float u_coverageCutoffVertex;
43699
+ //#water
43671
43700
  uniform vec2 u_extentMetres;
43672
43701
  uniform vec2 u_waveOrigin;
43702
+ //#endwater
43673
43703
 
43674
43704
  out vec2 v_st;
43675
43705
  out float v_value;
43676
43706
  out float v_coverage;
43707
+ //#water
43677
43708
  out vec3 v_positionEC;
43678
43709
  out vec3 v_eastEC;
43679
43710
  out vec3 v_northEC;
43680
43711
  out vec3 v_upEC;
43681
43712
  out vec2 v_waveMetres;
43713
+ //#endwater
43682
43714
 
43683
43715
  float decodeGround(vec2 uv) {
43684
43716
  // Channels arrive normalised to 0..1, so they go back to bytes before being reassembled.
@@ -43798,6 +43830,7 @@ void main() {
43798
43830
  // would be lost to float32 rounding at an earth radius.
43799
43831
  vec4 p = czm_translateRelativeToEye(position3DHigh, position3DLow + normal * displacement);
43800
43832
 
43833
+ //#water
43801
43834
  // The local frame at this vertex so a shading normal built in east/north/up meters can be turned into something usable.
43802
43835
  v_upEC = czm_normal * normal;
43803
43836
  vec3 east = normalize(cross(vec3(0.0, 0.0, 1.0), normal));
@@ -43805,16 +43838,9 @@ void main() {
43805
43838
  v_northEC = czm_normal * cross(normal, east);
43806
43839
  v_positionEC = (czm_modelViewRelativeToEye * p).xyz;
43807
43840
 
43808
- /*
43809
- * Where this vertex sits in the ripple field, in metres from an origin that follows the camera.
43810
- *
43811
- * Subtracted here rather than in the fragment shader because the position it is subtracted from
43812
- * spans the whole archive, which over a sound is tens of kilometres. A wave number times that
43813
- * is thousands of radians, and no fragment shader that may only have mediump can step through a
43814
- * cosine at that magnitude: the ripples come out as a flat surface, which is what a first cut of
43815
- * this did. What crosses into the fragment shader is a small number the camera is standing in.
43816
- */
43841
+ // Where this vertex sits in the ripple field, in metres from an origin that follows the camera.
43817
43842
  v_waveMetres = st * u_extentMetres - u_waveOrigin;
43843
+ //#endwater
43818
43844
 
43819
43845
  gl_Position = czm_modelViewProjectionRelativeToEye * p;
43820
43846
  }
@@ -43828,7 +43854,7 @@ uniform float u_valuePacked;
43828
43854
  uniform float u_valueRange;
43829
43855
  uniform float u_exaggeration;
43830
43856
  uniform float u_metresPerTexel;
43831
- uniform float u_waterOn;
43857
+ //#water
43832
43858
  uniform float u_waterWavelength;
43833
43859
  uniform float u_waterAmplitude;
43834
43860
  uniform float u_waterReflectivity;
@@ -43840,15 +43866,18 @@ uniform vec4 u_wavePhase;
43840
43866
  uniform vec4 u_wavePhaseB;
43841
43867
  // Metres the whole ripple field repeats over.
43842
43868
  uniform float u_wavePeriod;
43869
+ //#endwater
43843
43870
 
43844
43871
  in vec2 v_st;
43845
43872
  in float v_value;
43846
43873
  in float v_coverage;
43874
+ //#water
43847
43875
  in vec3 v_positionEC;
43848
43876
  in vec3 v_eastEC;
43849
43877
  in vec3 v_northEC;
43850
43878
  in vec3 v_upEC;
43851
43879
  in vec2 v_waveMetres;
43880
+ //#endwater
43852
43881
 
43853
43882
  /*
43854
43883
  * Scaled per channel for the same reason the vertex shader's decode is: reassembling the pair reaches
@@ -43860,6 +43889,7 @@ float valueAt(vec2 uv) {
43860
43889
  return mix(texel.r, packed16, u_valuePacked);
43861
43890
  }
43862
43891
 
43892
+ //#water
43863
43893
  /*
43864
43894
  * Slope of the ripple field at a point, in metres of rise per metre travelled.
43865
43895
  */
@@ -43935,6 +43965,7 @@ vec4 water(vec3 relief, vec4 color) {
43935
43965
  alpha = clamp(alpha + (1.0 - alpha) * (fresnel * 0.55 + glint), 0.0, 1.0);
43936
43966
  return vec4(lit, alpha);
43937
43967
  }
43968
+ //#endwater
43938
43969
 
43939
43970
  void main() {
43940
43971
  if (v_coverage < u_coverageCutoff) {
@@ -43957,10 +43988,10 @@ void main() {
43957
43988
  float scale = u_valueRange * u_exaggeration;
43958
43989
  vec3 n = normalize(vec3((left - right) * scale, (down - up) * scale, 2.0 * u_metresPerTexel));
43959
43990
 
43960
- if (u_waterOn > 0.5) {
43961
- out_FragColor = water(n, color);
43962
- return;
43963
- }
43991
+ //#water
43992
+ out_FragColor = water(n, color);
43993
+ return;
43994
+ //#endwater
43964
43995
 
43965
43996
  float lambert = clamp(dot(n, normalize(vec3(-0.5, -0.6, 0.62))), 0.0, 1.0);
43966
43997
  color.rgb *= 0.45 + 0.9 * lambert;
@@ -43968,6 +43999,15 @@ void main() {
43968
43999
  out_FragColor = vec4(color.rgb, color.a * v_coverage);
43969
44000
  }
43970
44001
  `;
44002
+ /*
44003
+ * Strips the water-only regions out of a shader source unless this surface is drawing water.
44004
+ */
44005
+ function withWater(source, water) {
44006
+ if (water) {
44007
+ return source.replace(/^\/\/#(end)?water\n/gm, "");
44008
+ }
44009
+ return source.replace(/^\/\/#water\n[\s\S]*?^\/\/#endwater\n/gm, "");
44010
+ }
43971
44011
  /*
43972
44012
  * Rewrites a GLSL 300 es source into the GLSL 100 dialect older Cesium builds author in.
43973
44013
  */
@@ -44296,6 +44336,7 @@ void main() {
44296
44336
  this.texture = null;
44297
44337
  this.textureDirty = true;
44298
44338
  this.shaderProgram = null;
44339
+ this.shaderProgramWater = false;
44299
44340
  this.renderState = null;
44300
44341
  this.destroyed = false;
44301
44342
  this.lastEyePosition = null;
@@ -44315,6 +44356,10 @@ void main() {
44315
44356
  this.water = null;
44316
44357
  this.waterStartMs = now();
44317
44358
  this.waveOrigin = new Cartesian2(0, 0);
44359
+ this.extentMetresCache = null;
44360
+ // Written in place each frame rather than reallocated, since they are read per tile.
44361
+ this.wavePhaseScratch = [new Cartesian4(), new Cartesian4()];
44362
+ this.waterSkyScratch = new Cartesian3();
44318
44363
  this.followGround = Boolean(options.followGround);
44319
44364
  this.terrainProvider = options.terrainProvider || null;
44320
44365
  this.extent = options.extent;
@@ -44739,32 +44784,45 @@ void main() {
44739
44784
  * 0..1 surface coordinate into the real distance the ripple wavelength is measured in.
44740
44785
  */
44741
44786
  extentMetres() {
44787
+ // The extent never moves, and this is read once per tile per frame.
44788
+ if (this.extentMetresCache) {
44789
+ return this.extentMetresCache;
44790
+ }
44742
44791
  const southWest = Cartesian3.fromDegrees(this.extent.West, this.extent.South, 0);
44743
44792
  const southEast = Cartesian3.fromDegrees(this.extent.East, this.extent.South, 0);
44744
44793
  const northWest = Cartesian3.fromDegrees(this.extent.West, this.extent.North, 0);
44745
- return new Cartesian2(Math.max(1, Cartesian3.distance(southWest, southEast)), Math.max(1, Cartesian3.distance(southWest, northWest)));
44794
+ this.extentMetresCache = new Cartesian2(Math.max(1, Cartesian3.distance(southWest, southEast)), Math.max(1, Cartesian3.distance(southWest, northWest)));
44795
+ return this.extentMetresCache;
44746
44796
  }
44747
44797
  /*
44748
44798
  * Where each ripple layer has scrolled to, wrapped into one turn.
44749
44799
  */
44750
44800
  wavePhase(from) {
44751
44801
  var _a;
44802
+ const into = this.wavePhaseScratch[from / 4];
44752
44803
  const water = this.water;
44753
44804
  if (!water) {
44754
- return new Cartesian4(0, 0, 0, 0);
44805
+ return Cartesian4.clone(Cartesian4.ZERO, into);
44755
44806
  }
44756
44807
  const speed = (_a = water.speed) !== null && _a !== void 0 ? _a : DEFAULT_WATER_SPEED_METRES_PER_SECOND;
44757
44808
  const period = this.wavePeriod();
44758
44809
  const seconds = (now() - this.waterStartMs) / 1000;
44759
44810
  const base = waveCycles(WATER_WAVES[WATER_BASE_WAVE]);
44760
- const phases = WATER_WAVES.slice(from, from + 4).map((wave) => {
44811
+ const phaseAt = (index) => {
44812
+ const wave = WATER_WAVES[from + index];
44813
+ if (!wave) {
44814
+ return 0;
44815
+ }
44761
44816
  const cycles = waveCycles(wave);
44762
44817
  const waveNumber = 2 * Math.PI * cycles / period;
44763
44818
  const travels = Math.sqrt(base / cycles);
44764
- const travelled = seconds * speed * travels * waveNumber;
44765
- return travelled % (2 * Math.PI);
44766
- });
44767
- return new Cartesian4(phases[0] || 0, phases[1] || 0, phases[2] || 0, phases[3] || 0);
44819
+ return (seconds * speed * travels * waveNumber) % (2 * Math.PI);
44820
+ };
44821
+ into.x = phaseAt(0);
44822
+ into.y = phaseAt(1);
44823
+ into.z = phaseAt(2);
44824
+ into.w = phaseAt(3);
44825
+ return into;
44768
44826
  }
44769
44827
  wavePeriod() {
44770
44828
  const wavelength = (this.water && this.water.wavelength) || DEFAULT_WATER_WAVELENGTH_METRES;
@@ -44951,14 +45009,22 @@ void main() {
44951
45009
  return isFinite(nearest) ? Math.max(1, nearest) : 1;
44952
45010
  }
44953
45011
  commandFor(context, tile, mesh) {
45012
+ // Rebuilt when the effect is switched, since which program is wanted is part of it.
45013
+ const wantsWater = Boolean(this.water);
45014
+ if (this.shaderProgram && this.shaderProgramWater !== wantsWater) {
45015
+ this.shaderProgram = null;
45016
+ }
44954
45017
  if (!this.shaderProgram) {
44955
45018
  const glsl300 = usesGlsl300(context);
45019
+ const vertex = withWater(VERTEX_SHADER_GLSL300, wantsWater);
45020
+ const fragment = withWater(FRAGMENT_SHADER_GLSL300, wantsWater);
44956
45021
  this.shaderProgram = ShaderProgram.fromCache({
44957
45022
  context,
44958
- vertexShaderSource: glsl300 ? VERTEX_SHADER_GLSL300 : toGlsl100(VERTEX_SHADER_GLSL300, false),
44959
- fragmentShaderSource: glsl300 ? FRAGMENT_SHADER_GLSL300 : toGlsl100(FRAGMENT_SHADER_GLSL300, true),
45023
+ vertexShaderSource: glsl300 ? vertex : toGlsl100(vertex, false),
45024
+ fragmentShaderSource: glsl300 ? fragment : toGlsl100(fragment, true),
44960
45025
  attributeLocations: mesh.attributeLocations
44961
45026
  });
45027
+ this.shaderProgramWater = wantsWater;
44962
45028
  this.renderState = RenderState.fromCache({
44963
45029
  depthTest: { enabled: true },
44964
45030
  // Translucent ramp: blend, and leave the depth buffer to the opaque world.
@@ -45034,7 +45100,7 @@ void main() {
45034
45100
  },
45035
45101
  u_waterSky: () => {
45036
45102
  const sky = (self.water && self.water.skyColor) || DEFAULT_WATER_SKY_COLOR;
45037
- return new Cartesian3(sky.red / 255, sky.green / 255, sky.blue / 255);
45103
+ return Cartesian3.fromElements(sky.red / 255, sky.green / 255, sky.blue / 255, self.waterSkyScratch);
45038
45104
  },
45039
45105
  u_wavePhase: () => self.wavePhase(0),
45040
45106
  u_wavePhaseB: () => self.wavePhase(4),
@@ -45045,6 +45111,7 @@ void main() {
45045
45111
  });
45046
45112
  }
45047
45113
  // Bounding volume belongs to the mesh, so it follows whichever tier is drawing.
45114
+ tile.command.shaderProgram = this.shaderProgram;
45048
45115
  tile.command.vertexArray = mesh.vertexArray;
45049
45116
  tile.command.boundingVolume = mesh.boundingSphere;
45050
45117
  return tile.command;
@@ -47006,6 +47073,28 @@ var EntityRenderEngine;
47006
47073
  };
47007
47074
  }
47008
47075
  EntityRenderEngine.Render = Render;
47076
+ /**
47077
+ * Removes what a render produced that nothing has a record of, for a render whose caller has gone away.
47078
+ * @param params
47079
+ */
47080
+ function RemoveAll(params) {
47081
+ const { viewer, entities, register } = params;
47082
+ if (!entities || viewer.isDestroyed()) {
47083
+ return;
47084
+ }
47085
+ entities.forEach((entity) => {
47086
+ if (!entity || (register === null || register === void 0 ? void 0 : register.HasRego(entity))) {
47087
+ return;
47088
+ }
47089
+ try {
47090
+ Remove({ viewer, entity });
47091
+ }
47092
+ catch (e) {
47093
+ console.error("EntityRenderEngine.RemoveAll: failed to remove a visual:", e);
47094
+ }
47095
+ });
47096
+ }
47097
+ EntityRenderEngine.RemoveAll = RemoveAll;
47009
47098
  function Remove(params) {
47010
47099
  function doRemove(params) {
47011
47100
  const { viewer, entity, ignoreParent } = params;
@@ -47834,7 +47923,7 @@ var StyleUtils;
47834
47923
  StyleUtils.ApplyTypeStyle = ApplyTypeStyle;
47835
47924
  })(StyleUtils || (StyleUtils = {}));
47836
47925
 
47837
- const VERSION = "7.3.7";
47926
+ const VERSION = "7.3.8";
47838
47927
  /**
47839
47928
  * Updates the environment instance used by bruce-cesium to one specified.
47840
47929
  * This can be used to ensure that the instance a parent is referencing is shared between bruce-cesium, bruce-models, and the parent app.