Expand description
An infinite line defined by a point and a vector.
Fields
point: Point<S>
vector: Vector<S>
Implementations
sourceimpl<S: Scalar> Line<S>
impl<S: Scalar> Line<S>
pub fn intersection(&self, other: &Self) -> Option<Point<S>>
pub fn signed_distance_to_point(&self, p: &Point<S>) -> S
pub fn distance_to_point(&self, p: &Point<S>) -> S
pub fn equation(&self) -> LineEquation<S>
pub fn intersects_box(&self, rect: &Box2D<S>) -> bool
pub fn intersects_rect(&self, rect: &Rect<S>) -> bool
Trait Implementations
impl<S: Copy> Copy for Line<S>
Auto Trait Implementations
impl<S> RefUnwindSafe for Line<S> where
S: RefUnwindSafe,
impl<S> Send for Line<S> where
S: Send,
impl<S> Sync for Line<S> where
S: Sync,
impl<S> Unpin for Line<S> where
S: Unpin,
impl<S> UnwindSafe for Line<S> where
S: UnwindSafe,
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more