A state object to share the readback managers between all TileSamplerZ instances with the same tile storage. More...
Public Member Functions | |
State (ptr< GPUTileStorage > storage) | |
Creates a new State for the given tile storage. | |
Public Attributes | |
ptr< GPUTileStorage > | storage |
The tile storage for which this State is built. | |
ptr< FrameBuffer > | fbo |
Framebuffer object used to compute zmin and zmax of tiles. | |
BufferId | readBuffer |
Buffer of FBO used to read back the computed zmin and zmax values. | |
ptr< Program > | minmaxProg |
The custom "mipmapping" program used to compute min and max elevation values over a tile. | |
ptr< ReadbackManager > | tileReadback |
The readback manager used to perform asynchronous readbacks. | |
std::set< TreeZ *, TreeZSort > | needReadback |
The set of texture tile that need to be read back. | |
GPUTileStorage::GPUSlot * | cameraSlot |
The slot of storage corresponding to the quad below the camera. | |
vec2i | cameraOffset |
Relative offset in cameraSlot of the pixel under the camera. | |
unsigned int | lastFrame |
The last frame for which a readback was performed. |
A state object to share the readback managers between all TileSamplerZ instances with the same tile storage.
proland::TileSamplerZ::State::State | ( | ptr< GPUTileStorage > | storage | ) |
Creates a new State for the given tile storage.
Relative offset in cameraSlot of the pixel under the camera.
The value of this pixel is readback into TerrainNode::groundHeightAtCamera.
The slot of storage corresponding to the quad below the camera.
ptr<FrameBuffer> proland::TileSamplerZ::State::fbo |
Framebuffer object used to compute zmin and zmax of tiles.
unsigned int proland::TileSamplerZ::State::lastFrame |
The last frame for which a readback was performed.
This is used to avoid doing more readbacks per frame than specified in the readback managers, when several TileSamplerZ sharing the same State are used.
ptr<Program> proland::TileSamplerZ::State::minmaxProg |
The custom "mipmapping" program used to compute min and max elevation values over a tile.
std::set<TreeZ*, TreeZSort> proland::TileSamplerZ::State::needReadback |
The set of texture tile that need to be read back.
Buffer of FBO used to read back the computed zmin and zmax values.
The tile storage for which this State is built.
The readback manager used to perform asynchronous readbacks.