cesium-native 0.47.0
Loading...
Searching...
No Matches
Cesium3DTilesSelection::TileSelectionState Class Referencefinal

A description of the selection state of a Tile during the Tileset::updateViewGroup process. More...

#include <Cesium3DTilesSelection/TileSelectionState.h>

Public Types

enum class  Result {
  None = 0 , Culled = 1 , Rendered = 2 , Refined = 3 ,
  RenderedAndKicked = 4 , RefinedAndKicked = 5
}
 Enumeration of possible results of a TileSelectionState. More...
 

Public Member Functions

constexpr TileSelectionState () noexcept
 Initializes a new instance with TileSelectionState::Result::None.
 
constexpr TileSelectionState (Result result) noexcept
 Initializes a new instance with a given TileSelectionState::Result.
 
constexpr Result getResult () const noexcept
 Gets the result of selection.
 
constexpr bool wasKicked () const noexcept
 Determines if this tile or its descendents were kicked from the render list.
 
constexpr Result getOriginalResult () const noexcept
 Gets the original selection result prior to being kicked.
 
constexpr void kick () noexcept
 Marks this tile as "kicked".
 

Detailed Description

A description of the selection state of a Tile during the Tileset::updateViewGroup process.

Instances of this class are stored in a TilesetViewGroup for each visited Tile, and are used to track the state of the tile during the process of selecting tiles for rendering. The Tileset updates this state while traversing the tile hierarchy, tracking whether a tile was rendered, culled, or refined in the last frame.

Definition at line 19 of file TileSelectionState.h.

Member Enumeration Documentation

◆ Result

Enumeration of possible results of a TileSelectionState.

Enumerator
None 

There was no selection result.

This may be the case when the tile wasn't visited last frame.

Culled 

This tile was deemed not visible and culled.

Rendered 

The tile was selected for rendering.

Refined 

This tile did not meet the required screen-space error and was refined.

RenderedAndKicked 

This tile was rendered but then removed from the render list.

This tile was originally rendered, but it got kicked out of the render list in favor of an ancestor because some tiles in its subtree were not yet renderable.

RefinedAndKicked 

This tile was refined but then removed from the render list.

This tile was originally refined, but its rendered descendants got kicked out of the render list in favor of an ancestor because some tiles in its subtree were not yet renderable.

Definition at line 24 of file TileSelectionState.h.

Constructor & Destructor Documentation

◆ TileSelectionState() [1/2]

Cesium3DTilesSelection::TileSelectionState::TileSelectionState ( )
inlineconstexprnoexcept

Initializes a new instance with TileSelectionState::Result::None.

Definition at line 71 of file TileSelectionState.h.

◆ TileSelectionState() [2/2]

Cesium3DTilesSelection::TileSelectionState::TileSelectionState ( Result result)
inlineconstexprnoexcept

Initializes a new instance with a given TileSelectionState::Result.

Parameters
resultThe result of the selection.

Definition at line 79 of file TileSelectionState.h.

Member Function Documentation

◆ getOriginalResult()

Result Cesium3DTilesSelection::TileSelectionState::getOriginalResult ( ) const
inlineconstexprnoexcept

Gets the original selection result prior to being kicked.

If the tile wasn't kicked, the original value is returned.

Returns
The TileSelectionState::Result prior to being kicked.

Definition at line 111 of file TileSelectionState.h.

◆ getResult()

Result Cesium3DTilesSelection::TileSelectionState::getResult ( ) const
inlineconstexprnoexcept

Gets the result of selection.

Returns
The TileSelectionState::Result

Definition at line 86 of file TileSelectionState.h.

◆ kick()

void Cesium3DTilesSelection::TileSelectionState::kick ( )
inlineconstexprnoexcept

Marks this tile as "kicked".

Definition at line 127 of file TileSelectionState.h.

◆ wasKicked()

bool Cesium3DTilesSelection::TileSelectionState::wasKicked ( ) const
inlineconstexprnoexcept

Determines if this tile or its descendents were kicked from the render list.

In other words, if its last selection result was TileSelectionState::Result::RenderedAndKicked or TileSelectionState::Result::RefinedAndKicked.

Returns
true if the tile was kicked, and false otherwise

Definition at line 98 of file TileSelectionState.h.


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