bruce-models 2.7.2 → 2.7.4

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.
@@ -7693,16 +7693,26 @@ var EntityGlobe;
7693
7693
  const maxLon = viewRect.east;
7694
7694
  const MAX_CELLS = 150;
7695
7695
  const cellDegreeSize = getCellSizeFromHeight(viewRect.alt);
7696
- const curMinLon = floorValueToCellSize(cellDegreeSize, minLon);
7697
- const curMinLat = floorValueToCellSize(cellDegreeSize, minLat);
7696
+ let curMinLon = floorValueToCellSize(cellDegreeSize, minLon);
7697
+ let curMinLat = floorValueToCellSize(cellDegreeSize, minLat);
7698
+ // For larger views we add additional padding because our view-area culling is too strong.
7699
+ if (cellDegreeSize >= 2) {
7700
+ curMinLon -= cellDegreeSize;
7701
+ curMinLat -= cellDegreeSize;
7702
+ }
7698
7703
  let centerX = cameraPos === null || cameraPos === void 0 ? void 0 : cameraPos.longitude;
7699
7704
  let centerY = cameraPos === null || cameraPos === void 0 ? void 0 : cameraPos.latitude;
7700
7705
  if (isNaN(centerX) || isNaN(centerY)) {
7701
7706
  centerX = (minLon + maxLon) / 2;
7702
7707
  centerY = (minLat + maxLat) / 2;
7703
7708
  }
7704
- const width = Math.ceil((maxLon - curMinLon) / cellDegreeSize);
7705
- const height = Math.ceil((maxLat - curMinLat) / cellDegreeSize);
7709
+ let width = Math.ceil((maxLon - curMinLon) / cellDegreeSize);
7710
+ let height = Math.ceil((maxLat - curMinLat) / cellDegreeSize);
7711
+ // For larger views we add additional padding because our view-area culling is too strong.
7712
+ if (cellDegreeSize >= 2) {
7713
+ width += 1;
7714
+ height += 1;
7715
+ }
7706
7716
  const cellDistances = [];
7707
7717
  for (let x = 0; x < width; x++) {
7708
7718
  for (let y = 0; y < height; y++) {
@@ -7763,7 +7773,13 @@ function getCellSizeFromHeight(height) {
7763
7773
  else if (height < 500000) {
7764
7774
  return 1;
7765
7775
  }
7766
- return 1.5;
7776
+ else if (height < 1000000) {
7777
+ return 1.3;
7778
+ }
7779
+ else if (height < 1200000) {
7780
+ return 1.8;
7781
+ }
7782
+ return 4;
7767
7783
  }
7768
7784
  function isCellFetched(cell) {
7769
7785
  if (cell.Fetched) {
@@ -11394,6 +11410,8 @@ var Markup;
11394
11410
  (function (EType) {
11395
11411
  // Default, no special handling.
11396
11412
  EType["Default"] = "default";
11413
+ // Same as default but assumes there is no content within it.
11414
+ EType["Shape"] = "shape";
11397
11415
  // Callout, assumes it will be positioned in 3d space.
11398
11416
  // Assumes existence of line that is used to anchor it.
11399
11417
  EType["Callout"] = "callout";
@@ -11922,7 +11940,7 @@ var DataSource;
11922
11940
  DataSource.GetList = GetList;
11923
11941
  })(DataSource || (DataSource = {}));
11924
11942
 
11925
- const VERSION$1 = "2.7.2";
11943
+ const VERSION$1 = "2.7.4";
11926
11944
 
11927
11945
  export { VERSION$1 as VERSION, AnnDocument, CustomForm, CustomFormContent, AbstractApi, Api, BruceApi, CamApi, IdmApi, GlobalApi, GuardianApi, ApiGetters, Calculator, Bounds, BruceEvent, CacheControl, Camera, Cartes, Carto, Color, DelayQueue, Geometry, UTC, BruceVariable, LRUCache, EntityAttachmentType, EntityAttachment, EntityComment, EntityLink, EntityLod, EntityLodCategory, EntityRelationType, EntityRelation, EntitySource, EntityTag, EntityType, Entity, EntityGlobe, EntityFilterGetter, BatchedDataGetter, EntityCoords, EntityTypeVisualSettings, EntityAttribute, ClientFile, ProgramKey, ZoomControl, MenuItem, ProjectViewBookmark, ProjectView, ProjectViewLegacyTile, ProjectViewTile, PendingAction, MessageBroker, HostingLocation, Style, Tileset, Permission, Session, UserGroup, User, Account, AccountInvite, EncryptUtils, MathUtils, ObjectUtils, PathUtils, UrlUtils, DataLab, ImportCad, ImportCsv, ImportJson, ImportKml, ImportedFile, Markup, Uploader, Plugin, ENVIRONMENT, DataSource };
11928
11946
  //# sourceMappingURL=bruce-models.es5.js.map