Struct centerline::Centerline[][src]

pub struct Centerline<I1, F1> where
    I1: InputType + Neg<Output = I1>,
    F1: BaseFloat + Sync + OutputType + Neg<Output = F1>, 
{ pub segments: Vec<Line<I1>>, pub diagram: SyncVoronoiDiagram<I1, F1>, pub lines: Option<Vec<Line3<F1>>>, pub line_strings: Option<Vec<LineString3<F1>>>, // some fields omitted }

Center line calculation object. It: * calculates the segmented voronoi diagram. * Filter out voronoi edges based on the angle to input geometry. * Collects connected edges into line strings and line segments. * Performs line simplification on those line strings.

Fields

segments: Vec<Line<I1>>

the input data to the voronoi diagram

diagram: SyncVoronoiDiagram<I1, F1>

the voronoi diagram itself

lines: Option<Vec<Line3<F1>>>

the individual two-point edges

line_strings: Option<Vec<LineString3<F1>>>

concatenated connected edges

Implementations

impl<I1, F1> Centerline<I1, F1> where
    I1: InputType + Neg<Output = I1>,
    F1: BaseFloat + Sync + OutputType + Neg<Output = F1>, 
[src]

pub fn default() -> Self[src]

Creates a Centerline container with a set of segments

pub fn with_segments(segments: Vec<Line<I1>>) -> Self[src]

Creates a Centerline container with a set of segments

pub fn build_voronoi(&mut self) -> Result<(), CenterlineError>[src]

builds the voronoi diagram and filter out infinite edges and other ‘outside’ geometry

pub fn calculate_centerline(
    &mut self,
    dot_limit: F1,
    discrete_limit: F1,
    ignored_regions: Option<&Vec<(Aabb2<F1>, LineString2<F1>)>>
) -> Result<(), CenterlineError>
[src]

perform the angle-to-geometry test and filter out some edges. Collect the rest of the edges into connected line-strings and line segments.

pub fn ignored_edges(&self) -> Option<Yabf>[src]

returns a copy of the ignored edges bit field

pub fn rejected_edges(&self) -> Option<Yabf>[src]

returns a copy of the rejected edges bit field

pub fn retrieve_point(
    &self,
    cell_id: VoronoiCellIndex
) -> Result<Point<I1>, CenterlineError>
[src]

pub fn retrieve_segment(
    &self,
    cell_id: VoronoiCellIndex
) -> Result<Line<I1>, CenterlineError>
[src]

pub fn diagram(&self) -> &SyncVoronoiDiagram<I1, F1>[src]

returns a reference to the internal voronoi diagram

pub fn i2f(input: I1) -> F1[src]

Auto Trait Implementations

impl<I1, F1> RefUnwindSafe for Centerline<I1, F1> where
    F1: RefUnwindSafe,
    I1: RefUnwindSafe

impl<I1, F1> Send for Centerline<I1, F1> where
    F1: Send,
    I1: Send

impl<I1, F1> Sync for Centerline<I1, F1> where
    I1: Sync

impl<I1, F1> Unpin for Centerline<I1, F1> where
    F1: Unpin,
    I1: Unpin

impl<I1, F1> UnwindSafe for Centerline<I1, F1> where
    F1: UnwindSafe,
    I1: UnwindSafe

Blanket Implementations

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

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

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

impl<T> From<T> for T[src]

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

impl<T> Pointable for T

type Init = T

The type for initializers.

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

type Error = Infallible

The type returned in the event of a conversion error.

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

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

The type returned in the event of a conversion error.