pub struct Polygon2D { /* private fields */ }
Implementations§
Source§impl Polygon2D
impl Polygon2D
pub fn new(segments: Vec<Segment2D>) -> Self
pub fn with_points(points: &[Point2D]) -> Self
pub fn len(&self) -> usize
pub fn points(&self) -> impl Iterator<Item = Point2D> + '_
pub fn intersect_with_semiplane( &self, l: &Line2D, left_semiplane: bool, ) -> Option<Polygon2D>
pub fn intersect_with_semiplane_mut( &mut self, l: &Line2D, less_mode: bool, ) -> bool
pub fn skip_short_edge(&self, tol: f64) -> Self
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Polygon2D
impl RefUnwindSafe for Polygon2D
impl Send for Polygon2D
impl Sync for Polygon2D
impl Unpin for Polygon2D
impl UnwindSafe for Polygon2D
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