Struct cavalier_contours::polyline::PlineOffsetOptions
source · pub struct PlineOffsetOptions<'a, T = f64>where
T: Real,{
pub aabb_index: Option<&'a StaticAABB2DIndex<T>>,
pub handle_self_intersects: bool,
pub pos_equal_eps: T,
pub slice_join_eps: T,
pub offset_dist_eps: T,
}
Expand description
Struct to hold options parameters when performing polyline offset.
Fields§
§aabb_index: Option<&'a StaticAABB2DIndex<T>>
Spatial index of all the polyline segment bounding boxes (or boxes no smaller, e.g. using
PlineSource::create_approx_aabb_index is valid). If None
is given then it will be
computed internally. PlineSource::create_approx_aabb_index or
PlineSource::create_aabb_index may be used to create the spatial index, the only
restriction is that the spatial index bounding boxes must be at least big enough to contain
the segments.
handle_self_intersects: bool
If true then self intersects will be properly handled by the offset algorithm, if false then self intersecting polylines may not offset correctly. Handling self intersects of closed polylines requires more memory and computation.
pos_equal_eps: T
Fuzzy comparison epsilon used for determining if two positions are equal.
slice_join_eps: T
Fuzzy comparison epsilon used for determining if two positions are equal when stitching polyline slices together.
offset_dist_eps: T
Fuzzy comparison epsilon used when testing distance of slices to original polyline for validity.
Implementations§
Trait Implementations§
source§impl<'a, T> Clone for PlineOffsetOptions<'a, T>where
T: Real + Clone,
impl<'a, T> Clone for PlineOffsetOptions<'a, T>where T: Real + Clone,
source§fn clone(&self) -> PlineOffsetOptions<'a, T>
fn clone(&self) -> PlineOffsetOptions<'a, T>
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more