Struct delaunay2d::Delaunay2D
[−]
[src]
pub struct Delaunay2D { /* fields omitted */ }
Methods
impl Delaunay2D
[src]
fn new(center: (f64, f64), radius: f64) -> Delaunay2D
[src]
Builds a new Delaunay triangulator.
All points added to the triangulator must fall within the bounding box
centered at center
and extending in radius
in each direction
fn add_point(&mut self, p: (f64, f64))
[src]
Adds a point to the triangulation.
fn export_triangles(&self) -> Vec<Triangle>
[src]
Returns the triangles generated by the triangulation. Each triangle is a counter-clockwise triple of coordinate indices
fn get_adjacent(&self, t: &Triangle) -> Option<TNeighbours>
[src]
Returns the neighbours of a given triangle. The first neighbour is adjacent to the edge opposite the first vertex, etc.
fn export_points(&self) -> Vec<(f64, f64)>
[src]
Returns the list of points added to the triangulation.
fn export_voronoi_regions(&self) -> (Vec<(f64, f64)>, Vec<Vec<usize>>)
[src]
Returns the vertices of the Voronoi regions, and the indices of vertices forming each region.