cesium-native 0.43.0
Loading...
Searching...
No Matches
Cesium3DTilesContent::ImplicitTilingUtilities Class Reference

Helper functions for working with 3D Tiles implicit tiling. More...

#include <Cesium3DTilesContent/ImplicitTilingUtilities.h>

Static Public Member Functions

static std::string resolveUrl (const std::string &baseUrl, const std::string &urlTemplate, const CesiumGeometry::QuadtreeTileID &quadtreeID)
 Resolves a templatized implicit tiling URL with a quadtree tile ID.
 
static std::string resolveUrl (const std::string &baseUrl, const std::string &urlTemplate, const CesiumGeometry::OctreeTileID &octreeID)
 Resolves a templatized implicit tiling URL with an octree tile ID.
 
static double computeLevelDenominator (uint32_t level) noexcept
 Computes the denominator for a given implicit tile level.
 
static uint64_t computeMortonIndex (const CesiumGeometry::QuadtreeTileID &tileID)
 Computes the Morton index for a given quadtree tile within its level.
 
static uint64_t computeMortonIndex (const CesiumGeometry::OctreeTileID &tileID)
 Computes the Morton index for a given octree tile within its level.
 
static uint64_t computeRelativeMortonIndex (const CesiumGeometry::QuadtreeTileID &subtreeID, const CesiumGeometry::QuadtreeTileID &tileID)
 Computes the relative Morton index for a given quadtree tile within its level of a subtree root at the tile with the given quadtree ID.
 
static uint64_t computeRelativeMortonIndex (const CesiumGeometry::OctreeTileID &subtreeRootID, const CesiumGeometry::OctreeTileID &tileID)
 Computes the relative Morton index for a given octree tile within its level of a subtree rooted at the tile with the given octree ID.
 
static CesiumGeometry::QuadtreeTileID getSubtreeRootID (uint32_t subtreeLevels, const CesiumGeometry::QuadtreeTileID &tileID) noexcept
 Gets the ID of the root tile of the subtree that contains a given tile.
 
static CesiumGeometry::OctreeTileID getSubtreeRootID (uint32_t subtreeLevels, const CesiumGeometry::OctreeTileID &tileID) noexcept
 Gets the ID of the root tile of the subtree that contains a given tile.
 
static CesiumGeometry::QuadtreeTileID absoluteTileIDToRelative (const CesiumGeometry::QuadtreeTileID &rootID, const CesiumGeometry::QuadtreeTileID &tileID) noexcept
 Converts an absolute tile ID to a tile ID relative to a given root tile.
 
static CesiumGeometry::OctreeTileID absoluteTileIDToRelative (const CesiumGeometry::OctreeTileID &rootID, const CesiumGeometry::OctreeTileID &tileID) noexcept
 Converts an absolute tile ID to a tile ID relative to a given root tile.
 
static QuadtreeChildren getChildren (const CesiumGeometry::QuadtreeTileID &tileID) noexcept
 Gets a lightweight virtual container for enumerating the quadtree IDs of the children of a given quadtree tile.
 
static OctreeChildren getChildren (const CesiumGeometry::OctreeTileID &tileID) noexcept
 Gets a lightweight virtual container for enumerating the octree IDs of the children of a given octree tile.
 
static Cesium3DTiles::BoundingVolume computeBoundingVolume (const Cesium3DTiles::BoundingVolume &rootBoundingVolume, const CesiumGeometry::QuadtreeTileID &tileID, const CesiumGeospatial::Ellipsoid &ellipsoid=CesiumGeospatial::Ellipsoid::WGS84) noexcept
 Computes the bounding volume for an implicit quadtree tile with the given ID as a Cesium3DTiles::BoundingVolume.
 
static Cesium3DTiles::BoundingVolume computeBoundingVolume (const Cesium3DTiles::BoundingVolume &rootBoundingVolume, const CesiumGeometry::OctreeTileID &tileID, const CesiumGeospatial::Ellipsoid &ellipsoid=CesiumGeospatial::Ellipsoid::WGS84) noexcept
 Computes the bounding volume for an implicit octree tile with the given ID as a Cesium3DTiles::BoundingVolume.
 
static CesiumGeospatial::BoundingRegion computeBoundingVolume (const CesiumGeospatial::BoundingRegion &rootBoundingVolume, const CesiumGeometry::QuadtreeTileID &tileID, const CesiumGeospatial::Ellipsoid &ellipsoid=CesiumGeospatial::Ellipsoid::WGS84) noexcept
 Computes the bounding volume for an implicit quadtree tile with the given ID as a bounding region.
 
static CesiumGeospatial::BoundingRegion computeBoundingVolume (const CesiumGeospatial::BoundingRegion &rootBoundingVolume, const CesiumGeometry::OctreeTileID &tileID, const CesiumGeospatial::Ellipsoid &ellipsoid=CesiumGeospatial::Ellipsoid::WGS84) noexcept
 Computes the bounding volume for an implicit octree tile with the given ID as a bounding region.
 
static CesiumGeometry::OrientedBoundingBox computeBoundingVolume (const CesiumGeometry::OrientedBoundingBox &rootBoundingVolume, const CesiumGeometry::QuadtreeTileID &tileID) noexcept
 Computes the bounding volume for an implicit quadtree tile with the given ID as an oriented bounding box.
 
static CesiumGeometry::OrientedBoundingBox computeBoundingVolume (const CesiumGeometry::OrientedBoundingBox &rootBoundingVolume, const CesiumGeometry::OctreeTileID &tileID) noexcept
 Computes the bounding volume for an implicit octree tile with the given ID as an oriented bounding box.
 
static CesiumGeospatial::S2CellBoundingVolume computeBoundingVolume (const CesiumGeospatial::S2CellBoundingVolume &rootBoundingVolume, const CesiumGeometry::QuadtreeTileID &tileID, const CesiumGeospatial::Ellipsoid &ellipsoid=CesiumGeospatial::Ellipsoid::WGS84) noexcept
 Computes the bounding volume for an implicit quadtree tile with the given ID as an S2 cell bounding volume.
 
static CesiumGeospatial::S2CellBoundingVolume computeBoundingVolume (const CesiumGeospatial::S2CellBoundingVolume &rootBoundingVolume, const CesiumGeometry::OctreeTileID &tileID, const CesiumGeospatial::Ellipsoid &ellipsoid=CesiumGeospatial::Ellipsoid::WGS84) noexcept
 Computes the bounding volume for an implicit octree tile with the given ID as an S2 cell bounding volume.
 

Detailed Description

Helper functions for working with 3D Tiles implicit tiling.

Definition at line 234 of file ImplicitTilingUtilities.h.

Member Function Documentation

◆ absoluteTileIDToRelative() [1/2]

static CesiumGeometry::OctreeTileID Cesium3DTilesContent::ImplicitTilingUtilities::absoluteTileIDToRelative ( const CesiumGeometry::OctreeTileID & rootID,
const CesiumGeometry::OctreeTileID & tileID )
staticnoexcept

Converts an absolute tile ID to a tile ID relative to a given root tile.

For example, if rootID and tileID are the same, this method returns OctreeTileID(0, 0, 0, 0).

Parameters
rootIDThe ID of the root tile that the returned ID should be relative to.
tileIDThe absolute ID of the tile to compute a relative ID for.
Returns
The relative tile ID.

◆ absoluteTileIDToRelative() [2/2]

static CesiumGeometry::QuadtreeTileID Cesium3DTilesContent::ImplicitTilingUtilities::absoluteTileIDToRelative ( const CesiumGeometry::QuadtreeTileID & rootID,
const CesiumGeometry::QuadtreeTileID & tileID )
staticnoexcept

Converts an absolute tile ID to a tile ID relative to a given root tile.

For example, if rootID and tileID are the same, this method returns QuadtreeTileID(0, 0, 0).

Parameters
rootIDThe ID of the root tile that the returned ID should be relative to.
tileIDThe absolute ID of the tile to compute a relative ID for.
Returns
The relative tile ID.

◆ computeBoundingVolume() [1/8]

static Cesium3DTiles::BoundingVolume Cesium3DTilesContent::ImplicitTilingUtilities::computeBoundingVolume ( const Cesium3DTiles::BoundingVolume & rootBoundingVolume,
const CesiumGeometry::OctreeTileID & tileID,
const CesiumGeospatial::Ellipsoid & ellipsoid = CesiumGeospatial::Ellipsoid::WGS84 )
staticnoexcept

Computes the bounding volume for an implicit octree tile with the given ID as a Cesium3DTiles::BoundingVolume.

Parameters
rootBoundingVolumeThe bounding volume of the root tile.
tileIDThe tile ID for which to compute the bounding volume.
ellipsoidThe ellipsoid to use for this calculation.
Returns
The bounding volume for the given implicit tile.

◆ computeBoundingVolume() [2/8]

static Cesium3DTiles::BoundingVolume Cesium3DTilesContent::ImplicitTilingUtilities::computeBoundingVolume ( const Cesium3DTiles::BoundingVolume & rootBoundingVolume,
const CesiumGeometry::QuadtreeTileID & tileID,
const CesiumGeospatial::Ellipsoid & ellipsoid = CesiumGeospatial::Ellipsoid::WGS84 )
staticnoexcept

Computes the bounding volume for an implicit quadtree tile with the given ID as a Cesium3DTiles::BoundingVolume.

Parameters
rootBoundingVolumeThe bounding volume of the root tile.
tileIDThe tile ID for which to compute the bounding volume.
ellipsoidThe ellipsoid to use for this calculation.
Returns
The bounding volume for the given implicit tile.

◆ computeBoundingVolume() [3/8]

static CesiumGeometry::OrientedBoundingBox Cesium3DTilesContent::ImplicitTilingUtilities::computeBoundingVolume ( const CesiumGeometry::OrientedBoundingBox & rootBoundingVolume,
const CesiumGeometry::OctreeTileID & tileID )
staticnoexcept

Computes the bounding volume for an implicit octree tile with the given ID as an oriented bounding box.

Parameters
rootBoundingVolumeThe oriented bounding box of the root tile.
tileIDThe tile ID for which to compute the oriented bounding box.
Returns
The oriented bounding box for the given implicit tile.

◆ computeBoundingVolume() [4/8]

static CesiumGeometry::OrientedBoundingBox Cesium3DTilesContent::ImplicitTilingUtilities::computeBoundingVolume ( const CesiumGeometry::OrientedBoundingBox & rootBoundingVolume,
const CesiumGeometry::QuadtreeTileID & tileID )
staticnoexcept

Computes the bounding volume for an implicit quadtree tile with the given ID as an oriented bounding box.

Parameters
rootBoundingVolumeThe oriented bounding box of the root tile.
tileIDThe tile ID for which to compute the oriented bounding box.
Returns
The oriented bounding box for the given implicit tile.

◆ computeBoundingVolume() [5/8]

static CesiumGeospatial::BoundingRegion Cesium3DTilesContent::ImplicitTilingUtilities::computeBoundingVolume ( const CesiumGeospatial::BoundingRegion & rootBoundingVolume,
const CesiumGeometry::OctreeTileID & tileID,
const CesiumGeospatial::Ellipsoid & ellipsoid = CesiumGeospatial::Ellipsoid::WGS84 )
staticnoexcept

Computes the bounding volume for an implicit octree tile with the given ID as a bounding region.

Parameters
rootBoundingVolumeThe bounding region of the root tile.
tileIDThe tile ID for which to compute the bounding region.
ellipsoidThe ellipsoid to use for this calculation.
Returns
The bounding region for the given implicit tile.

◆ computeBoundingVolume() [6/8]

static CesiumGeospatial::BoundingRegion Cesium3DTilesContent::ImplicitTilingUtilities::computeBoundingVolume ( const CesiumGeospatial::BoundingRegion & rootBoundingVolume,
const CesiumGeometry::QuadtreeTileID & tileID,
const CesiumGeospatial::Ellipsoid & ellipsoid = CesiumGeospatial::Ellipsoid::WGS84 )
staticnoexcept

Computes the bounding volume for an implicit quadtree tile with the given ID as a bounding region.

Parameters
rootBoundingVolumeThe bounding region of the root tile.
tileIDThe tile ID for which to compute the bounding region.
ellipsoidThe ellipsoid to use for this calculation.
Returns
The bounding region for the given implicit tile.

◆ computeBoundingVolume() [7/8]

static CesiumGeospatial::S2CellBoundingVolume Cesium3DTilesContent::ImplicitTilingUtilities::computeBoundingVolume ( const CesiumGeospatial::S2CellBoundingVolume & rootBoundingVolume,
const CesiumGeometry::OctreeTileID & tileID,
const CesiumGeospatial::Ellipsoid & ellipsoid = CesiumGeospatial::Ellipsoid::WGS84 )
staticnoexcept

Computes the bounding volume for an implicit octree tile with the given ID as an S2 cell bounding volume.

Parameters
rootBoundingVolumeThe S2 cell bounding volume of the root tile.
tileIDThe tile ID for which to compute the S2 cell bounding volume.
ellipsoidThe ellipsoid to use for this calculation.
Returns
The S2 cell bounding volume for the given implicit tile.

◆ computeBoundingVolume() [8/8]

static CesiumGeospatial::S2CellBoundingVolume Cesium3DTilesContent::ImplicitTilingUtilities::computeBoundingVolume ( const CesiumGeospatial::S2CellBoundingVolume & rootBoundingVolume,
const CesiumGeometry::QuadtreeTileID & tileID,
const CesiumGeospatial::Ellipsoid & ellipsoid = CesiumGeospatial::Ellipsoid::WGS84 )
staticnoexcept

Computes the bounding volume for an implicit quadtree tile with the given ID as an S2 cell bounding volume.

Parameters
rootBoundingVolumeThe S2 cell bounding volume of the root tile.
tileIDThe tile ID for which to compute the S2 cell bounding volume.
ellipsoidThe ellipsoid to use for this calculation.
Returns
The S2 cell bounding volume for the given implicit tile.

◆ computeLevelDenominator()

static double Cesium3DTilesContent::ImplicitTilingUtilities::computeLevelDenominator ( uint32_t level)
staticnoexcept

Computes the denominator for a given implicit tile level.

Divide the root tile's geometric error by this value to get the standard geometric error for tiles on the level. Or divide each component of a bounding volume by this factor to get the size of the bounding volume along that axis for tiles of this level.

Parameters
levelThe tile level.
Returns
The denominator for the level.

◆ computeMortonIndex() [1/2]

static uint64_t Cesium3DTilesContent::ImplicitTilingUtilities::computeMortonIndex ( const CesiumGeometry::OctreeTileID & tileID)
static

Computes the Morton index for a given octree tile within its level.

Parameters
tileIDThe ID of the tile.
Returns
The Morton index.

◆ computeMortonIndex() [2/2]

static uint64_t Cesium3DTilesContent::ImplicitTilingUtilities::computeMortonIndex ( const CesiumGeometry::QuadtreeTileID & tileID)
static

Computes the Morton index for a given quadtree tile within its level.

Parameters
tileIDThe ID of the tile.
Returns
The Morton index.

◆ computeRelativeMortonIndex() [1/2]

static uint64_t Cesium3DTilesContent::ImplicitTilingUtilities::computeRelativeMortonIndex ( const CesiumGeometry::OctreeTileID & subtreeRootID,
const CesiumGeometry::OctreeTileID & tileID )
static

Computes the relative Morton index for a given octree tile within its level of a subtree rooted at the tile with the given octree ID.

Parameters
subtreeRootIDThe ID of the subtree the contains the tile.
tileIDThe ID of the tile.
Returns
The relative Morton index.

◆ computeRelativeMortonIndex() [2/2]

static uint64_t Cesium3DTilesContent::ImplicitTilingUtilities::computeRelativeMortonIndex ( const CesiumGeometry::QuadtreeTileID & subtreeID,
const CesiumGeometry::QuadtreeTileID & tileID )
static

Computes the relative Morton index for a given quadtree tile within its level of a subtree root at the tile with the given quadtree ID.

Parameters
subtreeIDThe ID of the subtree the contains the tile.
tileIDThe ID of the tile.
Returns
The relative Morton index.

◆ getChildren() [1/2]

static OctreeChildren Cesium3DTilesContent::ImplicitTilingUtilities::getChildren ( const CesiumGeometry::OctreeTileID & tileID)
inlinestaticnoexcept

Gets a lightweight virtual container for enumerating the octree IDs of the children of a given octree tile.

Parameters
tileIDThe tile ID of the parent tile for which to get children.
Returns
The children.

Definition at line 404 of file ImplicitTilingUtilities.h.

◆ getChildren() [2/2]

static QuadtreeChildren Cesium3DTilesContent::ImplicitTilingUtilities::getChildren ( const CesiumGeometry::QuadtreeTileID & tileID)
inlinestaticnoexcept

Gets a lightweight virtual container for enumerating the quadtree IDs of the children of a given quadtree tile.

Parameters
tileIDThe tile ID of the parent tile for which to get children.
Returns
The children.

Definition at line 392 of file ImplicitTilingUtilities.h.

◆ getSubtreeRootID() [1/2]

static CesiumGeometry::OctreeTileID Cesium3DTilesContent::ImplicitTilingUtilities::getSubtreeRootID ( uint32_t subtreeLevels,
const CesiumGeometry::OctreeTileID & tileID )
staticnoexcept

Gets the ID of the root tile of the subtree that contains a given tile.

Parameters
subtreeLevelsThe number of levels in each sub-tree. For example, if this parameter is 4, then the first subtree starts at level 0 and contains tiles in levels 0 through 3, and the next subtree starts at level 4 and contains tiles in levels 4 through 7.
tileIDThe tile ID for each to find the subtree root.
Returns
The ID of the root tile of the subtree.

◆ getSubtreeRootID() [2/2]

static CesiumGeometry::QuadtreeTileID Cesium3DTilesContent::ImplicitTilingUtilities::getSubtreeRootID ( uint32_t subtreeLevels,
const CesiumGeometry::QuadtreeTileID & tileID )
staticnoexcept

Gets the ID of the root tile of the subtree that contains a given tile.

Parameters
subtreeLevelsThe number of levels in each sub-tree. For example, if this parameter is 4, then the first subtree starts at level 0 and contains tiles in levels 0 through 3, and the next subtree starts at level 4 and contains tiles in levels 4 through 7.
tileIDThe tile ID for each to find the subtree root.
Returns
The ID of the root tile of the subtree.

◆ resolveUrl() [1/2]

static std::string Cesium3DTilesContent::ImplicitTilingUtilities::resolveUrl ( const std::string & baseUrl,
const std::string & urlTemplate,
const CesiumGeometry::OctreeTileID & octreeID )
static

Resolves a templatized implicit tiling URL with an octree tile ID.

Parameters
baseUrlThe base URL that is used to resolve the urlTemplate if it is a relative path.
urlTemplateThe templatized URL.
octreeIDThe octree ID to use in resolving the parameters in the URL template.
Returns
The resolved URL.

◆ resolveUrl() [2/2]

static std::string Cesium3DTilesContent::ImplicitTilingUtilities::resolveUrl ( const std::string & baseUrl,
const std::string & urlTemplate,
const CesiumGeometry::QuadtreeTileID & quadtreeID )
static

Resolves a templatized implicit tiling URL with a quadtree tile ID.

Parameters
baseUrlThe base URL that is used to resolve the urlTemplate if it is a relative path.
urlTemplateThe templatized URL.
quadtreeIDThe quadtree ID to use in resolving the parameters in the URL template.
Returns
The resolved URL.

The documentation for this class was generated from the following file: