pub struct SPSurrogate {
pub convex_hull_indices: Vec<usize>,
pub poles: Vec<Circle>,
pub poles_bounding_circle: Circle,
pub max_distance_point_to_pole: fsize,
pub piers: Vec<Edge>,
pub n_ff_poles: usize,
pub convex_hull_area: fsize,
pub config: SPSurrogateConfig,
}
Expand description
Surrogate representation of a SimplePolygon for fail-fast purposes
Fields§
§convex_hull_indices: Vec<usize>
Indices of the points in the SimplePolygon that form the convex hull
poles: Vec<Circle>
Set of poles
poles_bounding_circle: Circle
Circle in which all poles are contained
max_distance_point_to_pole: fsize
The maximum distance from any point in the SP to a pole
piers: Vec<Edge>
Set of piers
n_ff_poles: usize
Number of poles that will be checked during fail-fast
convex_hull_area: fsize
The area of the convex hull of the SimplePolygon.
config: SPSurrogateConfig
The configuration used to generate the surrogate
Implementations§
Source§impl SPSurrogate
impl SPSurrogate
Sourcepub fn new(simple_poly: &SimplePolygon, config: SPSurrogateConfig) -> Self
pub fn new(simple_poly: &SimplePolygon, config: SPSurrogateConfig) -> Self
Creates a new SPSurrogate from a SimplePolygon and a configuration. Expensive operations are performed here, so this should be done here!
pub fn ff_poles(&self) -> &[Circle]
pub fn ff_piers(&self) -> &[Edge]
Trait Implementations§
Source§impl Clone for SPSurrogate
impl Clone for SPSurrogate
Source§fn clone(&self) -> SPSurrogate
fn clone(&self) -> SPSurrogate
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for SPSurrogate
impl Debug for SPSurrogate
Source§impl Transformable for SPSurrogate
impl Transformable for SPSurrogate
fn transform(&mut self, t: &Transformation) -> &mut Self
fn transform_clone(&self, t: &Transformation) -> Self
Source§impl TransformableFrom for SPSurrogate
impl TransformableFrom for SPSurrogate
fn transform_from(&mut self, reference: &Self, t: &Transformation) -> &mut Self
Auto Trait Implementations§
impl Freeze for SPSurrogate
impl RefUnwindSafe for SPSurrogate
impl Send for SPSurrogate
impl Sync for SPSurrogate
impl Unpin for SPSurrogate
impl UnwindSafe for SPSurrogate
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more