[][src]Struct rg3d_core::math::plane::Plane

pub struct Plane {
    pub normal: Vec3,
    pub d: f32,
}

Fields

normal: Vec3d: f32

Implementations

impl Plane[src]

pub fn from_normal_and_point(normal: &Vec3, point: &Vec3) -> Result<Self, ()>[src]

Creates plane from a point and normal vector at that point. May fail if normal is degenerated vector.

pub fn from_abcd(a: f32, b: f32, c: f32, d: f32) -> Result<Self, ()>[src]

Creates plane using coefficients of plane equation Ax + By + Cz + D = 0 May fail if length of normal vector is zero (normal is degenerated vector).

pub fn dot(&self, point: &Vec3) -> f32[src]

pub fn distance(&self, point: &Vec3) -> f32[src]

pub fn intersection_point(&self, b: &Plane, c: &Plane) -> Vec3[src]

http://geomalgorithms.com/a05-_intersect-1.html

Trait Implementations

impl Clone for Plane[src]

impl Copy for Plane[src]

impl Debug for Plane[src]

impl Default for Plane[src]

impl Visit for Plane[src]

Auto Trait Implementations

impl RefUnwindSafe for Plane

impl Send for Plane

impl Sync for Plane

impl Unpin for Plane

impl UnwindSafe for Plane

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> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 

impl<T> Visit for T where
    T: FieldData + 'static, 
[src]