An AbstractTask to draw a terrain. More...
#include <DrawTerrainTask.h>
Classes | |
class | Impl |
A Task to draw a terrain. More... | |
Public Member Functions | |
DrawTerrainTask (const QualifiedName &terrain, const QualifiedName &mesh, bool culling) | |
Creates a new DrawTerrainTask. | |
virtual | ~DrawTerrainTask () |
Deletes this DrawTerrainTask. | |
Protected Member Functions | |
DrawTerrainTask () | |
Creates an uninitialized DrawTerrainTask. | |
void | init (const QualifiedName &terrain, const QualifiedName &mesh, bool culling) |
Initializes this DrawTerrainTask. | |
Private Attributes | |
QualifiedName | terrain |
The terrain to be drawn. | |
QualifiedName | mesh |
The mesh to be drawn for each terrain quad. | |
bool | culling |
True to draw only visible leaf quads, false to draw all leaf quads. |
An AbstractTask to draw a terrain.
This task draws a mesh for each visible leaf quad of the terrain quadtree, using the current program and framebuffers. Before drawing each quad, this task calls TileSampler::setTile on each TileSampler associated with the TerrainNode in its owner SceneNode. It also calls the Deformation::setUniforms methods using the terrain deformation.
proland::DrawTerrainTask::DrawTerrainTask | ( | const QualifiedName & | terrain, | |
const QualifiedName & | mesh, | |||
bool | culling | |||
) |
Creates a new DrawTerrainTask.
terrain | the terrain to be drawn. The first part of this "node.name" qualified name specifies the scene node containing the TerrainNode field. The second part specifies the name of this TerrainNode field. | |
mesh | the mesh to be used to draw each quad. The first part of this "node.name" qualified name specifies the scene node containing the mesh field. The second part specifies the name of this mesh field. | |
culling | true to draw only visible leaf quads, false to draw all leaf quads. |
virtual proland::DrawTerrainTask::~DrawTerrainTask | ( | ) | [virtual] |
Deletes this DrawTerrainTask.
proland::DrawTerrainTask::DrawTerrainTask | ( | ) | [protected] |
Creates an uninitialized DrawTerrainTask.
void proland::DrawTerrainTask::init | ( | const QualifiedName & | terrain, | |
const QualifiedName & | mesh, | |||
bool | culling | |||
) | [protected] |
Initializes this DrawTerrainTask.
terrain | the terrain to be drawn. The first part of this "node.name" qualified name specifies the scene node containing the TerrainNode field. The second part specifies the name of this TerrainNode field. | |
mesh | the mesh to be used to draw each quad. The first part of this "node.name" qualified name specifies the scene node containing the mesh field. The second part specifies the name of this mesh field. | |
culling | true to draw only visible leaf quads, false to draw all leaf quads. |
bool proland::DrawTerrainTask::culling [private] |
True to draw only visible leaf quads, false to draw all leaf quads.
QualifiedName proland::DrawTerrainTask::mesh [private] |
The mesh to be drawn for each terrain quad.
The first part of this "node.name" qualified name specifies the scene node containing the mesh field. The second part specifies the name of this mesh field.
QualifiedName proland::DrawTerrainTask::terrain [private] |
The terrain to be drawn.
The first part of this "node.name" qualified name specifies the scene node containing the TerrainNode field. The second part specifies the name of this TerrainNode field.