[][src]Struct startin::Triangulation

pub struct Triangulation { /* fields omitted */ }

Methods

impl Triangulation[src]

pub fn new() -> Triangulation[src]

pub fn set_snap_tolerance(&mut self, snaptol: f64) -> f64[src]

Set a snap tolerance when inserting new points: if the newly inserted one is closer than snap_tolerance to another one, then it is not inserted. Avoids having very close vertices (like at 0.00007mm) Default is 0.001unit (thus 1mm for most datasets).

pub fn get_snap_tolerance(&self) -> f64[src]

pub fn set_jump_and_walk(&mut self, b: bool)[src]

Activate/deactive the jump-and-walk strategy for locate(). If deactivated, then the walk starts from the last inserted triangle.

pub fn is_using_robust_predicates(&self) -> bool[src]

pub fn use_robust_predicates(&mut self, b: bool)[src]

pub fn insert_one_pt(
    &mut self,
    px: f64,
    py: f64,
    pz: f64
) -> Result<usize, usize>
[src]

pub fn get_point(&self, v: usize) -> Vec<f64>[src]

Returns the coordinates of the vertex v in a Vec [x,y,z]

pub fn adjacent_triangles_to_triangle(&self, tr: &Triangle) -> Vec<Triangle>[src]

pub fn incident_triangles_to_vertex(&self, v: usize) -> Vec<Triangle>[src]

pub fn adjacent_vertices_to_vertex(&self, v: usize) -> Vec<usize>[src]

pub fn is_triangle(&self, tr: &Triangle) -> bool[src]

Returns whether a triplet of indices is a Triangle in the triangulation.

pub fn statistics_degree(&self) -> (f64, usize, usize)[src]

pub fn number_of_vertices(&self) -> usize[src]

Returns number of finite vertices in the triangulation.

pub fn number_of_triangles(&self) -> usize[src]

Returns number of finite triangles in the triangulation.

pub fn convex_hull(&self) -> Vec<usize>[src]

Returns the convex hull of the dataset, oriented CCW. It is a list of vertex indices (first != last)

pub fn number_of_vertices_on_convex_hull(&self) -> usize[src]

Returns size of the convex hull of the dataset

pub fn is_vertex_convex_hull(&self, v: usize) -> bool[src]

Returns true if the vertex v is part of the boundary of the convex hull of the dataset. False otherwise.

pub fn locate(&self, px: f64, py: f64) -> Option<Triangle>[src]

Returns, if it exists, the Triangle containing (px,py). If it is direction on a vertex/edge, then one is randomly chosen.

pub fn all_vertices(&self) -> Vec<Vec<f64>>[src]

Returns a Vec<Vec> of all the finite vertices

pub fn is_valid(&self) -> bool[src]

pub fn write_obj(&self, path: String, twod: bool) -> Result<()>[src]

Trait Implementations

impl Display for Triangulation[src]

Auto Trait Implementations

Blanket Implementations

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T> From for T[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]