cesium-native
0.41.0
|
#include <Cesium3DTilesSelection/Tile.h>
Public Types | |
typedef CesiumUtility::DoublyLinkedList< Tile, &Tile::_loadedTilesLinks > | LoadedLinkedList |
A CesiumUtility::DoublyLinkedList for tile objects. | |
Public Member Functions | |
Tile (TilesetContentLoader *pLoader) noexcept | |
Construct a tile with unknown content and a loader that is used to load the content of this tile. Tile has Unloaded status when initializing with this constructor. More... | |
Tile (TilesetContentLoader *pLoader, std::unique_ptr< TileExternalContent > &&externalContent) noexcept | |
Construct a tile with an external content and a loader that is associated with this tile. Tile has ContentLoaded status when initializing with this constructor. More... | |
Tile (TilesetContentLoader *pLoader, TileEmptyContent emptyContent) noexcept | |
Construct a tile with an empty content and a loader that is associated with this tile. Tile has ContentLoaded status when initializing with this constructor. More... | |
~Tile () noexcept=default | |
Default destructor, which clears all resources associated with this tile. | |
Tile (const Tile &rhs)=delete | |
Copy constructor. More... | |
Tile (Tile &&rhs) noexcept | |
Move constructor. More... | |
Tile & | operator= (const Tile &rhs)=delete |
Copy constructor. More... | |
Tile & | operator= (Tile &&rhs) noexcept |
Move assignment operator. More... | |
Tile * | getParent () noexcept |
Returns the parent of this tile in the tile hierarchy. More... | |
const Tile * | getParent () const noexcept |
Returns the parent of this tile in the tile hierarchy. More... | |
gsl::span< Tile > | getChildren () noexcept |
Returns a view on the children of this tile. More... | |
gsl::span< const Tile > | getChildren () const noexcept |
Returns a view on the children of this tile. More... | |
void | createChildTiles (std::vector< Tile > &&children) |
Assigns the given child tiles to this tile. More... | |
const BoundingVolume & | getBoundingVolume () const noexcept |
Returns the BoundingVolume of this tile. More... | |
void | setBoundingVolume (const BoundingVolume &value) noexcept |
Set the BoundingVolume of this tile. More... | |
const std::optional< BoundingVolume > & | getViewerRequestVolume () const noexcept |
Returns the viewer request volume of this tile. More... | |
void | setViewerRequestVolume (const std::optional< BoundingVolume > &value) noexcept |
Set the viewer request volume of this tile. More... | |
double | getGeometricError () const noexcept |
Returns the geometric error of this tile. More... | |
void | setGeometricError (double value) noexcept |
Set the geometric error of the contents of this tile. More... | |
double | getNonZeroGeometricError () const noexcept |
Gets the tile's geometric error as if by calling getGeometricError, except that if the error is smaller than Math::Epsilon5 the returned geometric error is instead computed as half of the parent tile's (non-zero) geometric error. More... | |
bool | getUnconditionallyRefine () const noexcept |
Returns whether to unconditionally refine this tile. More... | |
void | setUnconditionallyRefine () noexcept |
Marks that this tile should be unconditionally refined. More... | |
TileRefine | getRefine () const noexcept |
The refinement strategy of this tile. More... | |
void | setRefine (TileRefine value) noexcept |
Set the refinement strategy of this tile. More... | |
const glm::dmat4x4 & | getTransform () const noexcept |
Gets the transformation matrix for this tile. More... | |
void | setTransform (const glm::dmat4x4 &value) noexcept |
Set the transformation matrix for this tile. More... | |
const TileID & | getTileID () const noexcept |
Returns the TileID of this tile. More... | |
void | setTileID (const TileID &id) noexcept |
Set the TileID of this tile. More... | |
const std::optional< BoundingVolume > & | getContentBoundingVolume () const noexcept |
Returns the BoundingVolume of the renderable content of this tile. More... | |
void | setContentBoundingVolume (const std::optional< BoundingVolume > &value) noexcept |
Set the BoundingVolume of the renderable content of this tile. More... | |
TileSelectionState & | getLastSelectionState () noexcept |
Returns the TileSelectionState of this tile. More... | |
const TileSelectionState & | getLastSelectionState () const noexcept |
Returns the TileSelectionState of this tile. More... | |
void | setLastSelectionState (const TileSelectionState &newState) noexcept |
Set the TileSelectionState of this tile. More... | |
int64_t | computeByteSize () const noexcept |
Determines the number of bytes in this tile's geometry and texture data. | |
std::vector< RasterMappedTo3DTile > & | getMappedRasterTiles () noexcept |
Returns the raster overlay tiles that have been mapped to this tile. | |
const std::vector< RasterMappedTo3DTile > & | getMappedRasterTiles () const noexcept |
Returns the raster overlay tiles that have been mapped to this tile. More... | |
const TileContent & | getContent () const noexcept |
get the content of the tile. | |
TileContent & | getContent () noexcept |
bool | isRenderable () const noexcept |
Determines if this tile is currently renderable. | |
bool | isRenderContent () const noexcept |
Determines if this tile has mesh content. | |
bool | isExternalContent () const noexcept |
Determines if this tile has external tileset content. | |
bool | isEmptyContent () const noexcept |
Determines if this tile has empty content. | |
TilesetContentLoader * | getLoader () const noexcept |
get the loader that is used to load the tile content. | |
TileLoadState | getState () const noexcept |
Returns the TileLoadState of this tile. | |
Friends | |
class | TilesetContentManager |
class | MockTilesetContentManagerTestFixture |
A tile in a Tileset.
The tiles of a tileset form a hierarchy, where each tile may contain renderable content, and each tile has an associated bounding volume.
The actual hierarchy is represented with the Tile::getParent and Tile::getChildren functions.
The renderable content is provided as a TileContentLoadResult from the Tile::getContent function. The Tile::getGeometricError function returns the geometric error of the representation of the renderable content of a tile.
The BoundingVolume is given by the Tile::getBoundingVolume function. This bounding volume encloses the renderable content of the tile itself, as well as the renderable content of all children, yielding a spatially coherent hierarchy of bounding volumes.
The bounding volume of the content of an individual tile is given by the Tile::getContentBoundingVolume function.
|
explicitnoexcept |
Construct a tile with unknown content and a loader that is used to load the content of this tile. Tile has Unloaded status when initializing with this constructor.
pLoader | The TilesetContentLoader that is used to load the tile. |
|
noexcept |
Construct a tile with an external content and a loader that is associated with this tile. Tile has ContentLoaded status when initializing with this constructor.
pLoader | The TilesetContentLoader that is assiocated with this tile. |
|
noexcept |
Construct a tile with an empty content and a loader that is associated with this tile. Tile has ContentLoaded status when initializing with this constructor.
pLoader | The TilesetContentLoader that is assiocated with this tile. |
|
delete |
Copy constructor.
rhs | The other instance. |
|
noexcept |
Move constructor.
rhs | The other instance. |
void Cesium3DTilesSelection::Tile::createChildTiles | ( | std::vector< Tile > && | children | ) |
Assigns the given child tiles to this tile.
This function is not supposed to be called by clients.
children | The child tiles. |
<tt>std::runtime_error</tt> | if this tile already has children. |
|
inlinenoexcept |
Returns the BoundingVolume of this tile.
This is a bounding volume that encloses the content of this tile, as well as the content of all child tiles.
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
Returns the BoundingVolume of the renderable content of this tile.
The content bounding volume is a bounding volume that tightly fits only the renderable content of the tile. This enables tighter view frustum culling, making it possible to exclude from rendering any content not in the view frustum.
|
inlinenoexcept |
Returns the geometric error of this tile.
This is the error, in meters, introduced if this tile is rendered and its children are not. This is used to compute screen space error, i.e., the error measured in pixels.
|
inlinenoexcept |
Returns the TileSelectionState of this tile.
This function is not supposed to be called by clients.
|
inlinenoexcept |
Returns the TileSelectionState of this tile.
This function is not supposed to be called by clients.
|
inlinenoexcept |
|
noexcept |
Gets the tile's geometric error as if by calling getGeometricError, except that if the error is smaller than Math::Epsilon5 the returned geometric error is instead computed as half of the parent tile's (non-zero) geometric error.
This is useful for determining when to refine what would ordinarily be a leaf tile, for example to attach more detailed raster overlays to it.
If this tile and all of its ancestors have a geometric error less than Math::Epsilon5, returns Math::Epsilon5.
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
The refinement strategy of this tile.
Returns the TileRefine value that indicates the refinement strategy for this tile. This is Add
when the content of the child tiles is added to the content of this tile during refinement, and Replace
when the content of the child tiles replaces the content of this tile during refinement.
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
Returns whether to unconditionally refine this tile.
This is useful in cases such as with external tilesets, where instead of a tile having any content, it points to an external tileset's root. So the tile always needs to be refined otherwise the external tileset will not be displayed.
|
inlinenoexcept |
Returns the viewer request volume of this tile.
The viewer request volume is an optional BoundingVolume that may be associated with a tile. It allows controlling the rendering process of the tile content: If the viewer request volume is present, then the content of the tile will only be rendered when the viewer (i.e. the camera position) is inside the viewer request volume.
Copy constructor.
rhs | The other instance. |
Move assignment operator.
rhs | The other instance. |
|
inlinenoexcept |
Set the BoundingVolume of this tile.
This function is not supposed to be called by clients.
value | The bounding volume. |
|
inlinenoexcept |
Set the BoundingVolume of the renderable content of this tile.
This function is not supposed to be called by clients.
value | The content bounding volume |
|
inlinenoexcept |
|
inlinenoexcept |
Set the TileSelectionState of this tile.
This function is not supposed to be called by clients.
newState | The new stace |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |
|
inlinenoexcept |