|
| Delaunay2 () |
| Default constructor.
|
|
| ~Delaunay2 () override |
| Destructor.
|
|
void | set_vertices (unsigned int nb_vertices, const float *pts) override |
| Sets the vertices from an array of floating point numbers, in which each consecutive number pair denotes a 2D point.
|
|
void | set_vertices (const std::vector< vec2 > &vertices) |
| Sets the vertices from an array of 2D points.
|
|
unsigned int | nearest_vertex (const float *p) const override |
| Finds the index of the nearest vertex to a given point.
|
|
unsigned int | nearest_vertex (const vec2 &p) const |
| Finds the index of the nearest vertex to a given 2D point.
|
|
const vec2 & | vertex (unsigned int i) const |
| Returns the coordinates of the vertex with index i .
|
|
const int * | tri_to_v () const |
| Returns the pointer to the triangle-to-vertex mapping.
|
|
const int * | tri_to_tri () const |
| Returns the pointer to the triangle-to-triangle mapping.
|
|
int | vertex_tri (int v) const |
| Returns the index of a triangle containing the vertex v .
|
|
unsigned int | nb_triangles () const |
| Returns the number of triangles.
|
|
int | tri_vertex (unsigned int t, unsigned int lv) const |
| Returns the index of the lv -th vertex in the t -th triangle.
|
|
int | tri_adjacent (unsigned int t, unsigned int le) const |
| Returns the index of the triangle adjacent to the le -th edge of the t -th triangle.
|
|
| Delaunay (unsigned int dimension) |
| Constructor.
|
|
virtual | ~Delaunay () |
| Virtual destructor.
|
|
unsigned int | dimension () const |
| Returns the dimension of the triangulation.
|
|
unsigned int | cell_size () const |
| Returns the size of a cell.
|
|
const float * | vertices_ptr () const |
| Returns a pointer to the vertices array.
|
|
const float * | vertex_ptr (unsigned int i) const |
| Returns a pointer to the vertex of index i .
|
|
unsigned int | nb_vertices () const |
| Returns the number of vertices.
|
|
unsigned int | nb_cells () const |
| Returns the number of cells.
|
|
const int * | cell_to_v () const |
| Returns a pointer to the cell-to-vertex mapping.
|
|
const int * | cell_to_cell () const |
| Returns a pointer to the cell-to-cell mapping.
|
|
int | cell_vertex (unsigned int c, unsigned int lv) const |
| Returns the index of the lv -th vertex in the c -th cell.
|
|
int | cell_adjacent (unsigned int c, unsigned int lf) const |
| Returns the index of the cell adjacent to the lf -th face of the c -th cell.
|
|
int | vertex_cell (unsigned int v) const |
| Returns the index of a cell containing the vertex v .
|
|
unsigned int | index (unsigned int c, int v) const |
| Returns the local index of vertex v within cell c .
|
|
unsigned int | adjacent_index (unsigned int c1, unsigned int c2) const |
| Returns the local index of the face shared by cells c1 and c2 .
|
|
unsigned int | next_around_vertex (unsigned int c, unsigned int lv) const |
| Returns the next cell around vertex lv in cell c .
|
|
virtual void | get_neighbors (unsigned int v, std::vector< unsigned int > &neighbors) const |
| Retrieves the one-ring neighbors of vertex v .
|
|
bool | check_duplicate_vertices () |
| Checks for duplicate vertices in stored neighbor lists.
|
|
2D Delaunay triangulation, using Jonathan Richard Shewchuk's "triangle" implementation.
This class provides functionality for 2D Delaunay triangulation using the "triangle" library. It manages vertices, triangles, and their relationships, and provides methods for querying the triangulation structure.
- See also
- Delaunay, Delaunay3