A geometric description of a Heightmap using a quad tree.
More...
#include <HeightMap.h>
|
HeightMapNode * | root_ |
|
Mesh | mesh_ |
| Should not be read or written to directly in general. Use setMesh and getMesh to write respectively read the mesh. In a few exceptions, the mesh can be written direcly. Make sure that mesh keeps consistent with other member variables. More...
|
|
A geometric description of a Heightmap using a quad tree.
Definition at line 15 of file HeightMap.h.
◆ HeightMap() [1/2]
geo::HeightMap::HeightMap |
( |
| ) |
|
◆ HeightMap() [2/2]
geo::HeightMap::HeightMap |
( |
const HeightMap & |
orig | ) |
|
◆ ~HeightMap()
geo::HeightMap::~HeightMap |
( |
| ) |
|
|
virtual |
◆ clone()
◆ createQuadTree()
HeightMapNode * geo::HeightMap::createQuadTree |
( |
const std::vector< std::vector< double > > & |
map, |
|
|
unsigned int |
mx_min, |
|
|
unsigned int |
my_min, |
|
|
unsigned int |
mx_max, |
|
|
unsigned int |
my_max, |
|
|
double |
resolution |
|
) |
| |
|
staticprotected |
createQuadTree: divide a grid over a quad tree
- Parameters
-
map | heightmap in the form of a grid. Must be square. |
mx_min | indices describing a square region in the map from which to create the node |
my_min | index to describe the region in the map |
mx_max | index to describe the region in the map |
my_max | index to describe the region in the map |
resolution | resolution of the map in meters per index. |
- Returns
- pointer to the root node of the quadtree.
Definition at line 194 of file HeightMap.cpp.
◆ fromGrid()
fromGrid: instantiate a Heightmap from a grid
- Parameters
-
grid | Heightmap in the form of a grid |
resolution | resolution of the grid in meters per index |
- Returns
- Heightmap
Definition at line 34 of file HeightMap.cpp.
◆ intersect()
bool geo::HeightMap::intersect |
( |
const Ray & |
r, |
|
|
float |
t0, |
|
|
float |
t1, |
|
|
double & |
distance |
|
) |
| const |
|
virtual |
intersect: currently always throws a logic error
- Parameters
-
- Returns
- true when the ray intersects the shape
Reimplemented from geo::Shape.
Definition at line 27 of file HeightMap.cpp.
◆ root_
The documentation for this class was generated from the following files: