[][src]Struct ncollide3d::shape::Cone

pub struct Cone<N> { /* fields omitted */ }

SupportMap description of a cylinder shape with its principal axis aligned with the y axis.

Methods

impl<N: Real> Cone<N>[src]

pub fn new(half_height: N, radius: N) -> Cone<N>[src]

Creates a new cone.

Arguments:

  • half_height - the half length of the cone along the y axis.
  • radius - the length of the cone along all other axis.

pub fn half_height(&self) -> N[src]

The cone half length along the y axis.

pub fn radius(&self) -> N[src]

The radius of the cone along all but the y axis.

Trait Implementations

impl<N: Real> HasBoundingVolume<N, AABB<N>> for Cone<N>[src]

impl<N: Real> HasBoundingVolume<N, BoundingSphere<N>> for Cone<N>[src]

impl<N: Real> PointQuery<N> for Cone<N>[src]

fn distance_to_point(&self, m: &Isometry<N>, pt: &Point<N>, solid: bool) -> N[src]

Computes the minimal distance between a point and self transformed by m.

fn contains_point(&self, m: &Isometry<N>, pt: &Point<N>) -> bool[src]

Tests if the given point is inside of self transformed by m.

impl<N: Real> RayCast<N> for Cone<N>[src]

fn toi_with_ray(&self, m: &Isometry<N>, ray: &Ray<N>, solid: bool) -> Option<N>[src]

Computes the time of impact between this transform shape and a ray.

fn toi_and_normal_and_uv_with_ray(
    &self,
    m: &Isometry<N>,
    ray: &Ray<N>,
    solid: bool
) -> Option<RayIntersection<N>>
[src]

Computes time of impact, normal, and texture coordinates (uv) between this transformed shape and a ray. Read more

fn intersects_ray(&self, m: &Isometry<N>, ray: &Ray<N>) -> bool[src]

Tests whether a ray intersects this transformed shape.

impl<N: Real> SupportMap<N> for Cone<N>[src]

fn support_point_toward(
    &self,
    transform: &Isometry<N>,
    dir: &Unit<Vector<N>>
) -> Point<N>
[src]

Same as self.support_point except that dir is normalized.

impl<N: Real> ToTriMesh<N> for Cone<N>[src]

type DiscretizationParameter = u32

impl<N: PartialEq> PartialEq<Cone<N>> for Cone<N>[src]

impl<N: Clone> Clone for Cone<N>[src]

fn clone_from(&mut self, source: &Self)
1.0.0
[src]

Performs copy-assignment from source. Read more

impl<N: Debug> Debug for Cone<N>[src]

Auto Trait Implementations

impl<N> Send for Cone<N> where
    N: Send

impl<N> Sync for Cone<N> where
    N: Sync

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto 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<T> Any for T where
    T: 'static + ?Sized
[src]

impl<SS, SP> SupersetOf for SP where
    SS: SubsetOf<SP>, 
[src]

impl<T> Downcast for T where
    T: Any
[src]

impl<T> Same for T

type Output = T

Should always be Self