[−][src]Struct ncollide_geometry::shape::Ball
A Ball shape.
Methods
impl<N: Real> Ball<N>
[src]
pub fn new(radius: N) -> Ball<N>
[src]
Creates a new ball from its radius and center.
pub fn radius(&self) -> N
[src]
The ball radius.
Trait Implementations
impl<P: Point, M: Isometry<P>> SupportMap<P, M> for Ball<P::Real>
[src]
fn support_point(&self, m: &M, dir: &P::Vector) -> P
[src]
fn support_point_toward(&self, m: &M, dir: &Unit<P::Vector>) -> P
[src]
fn support_area_toward(
&self,
transform: &M,
dir: &Unit<P::Vector>,
_angle: P::Real,
out: &mut Vec<P>
)
[src]
&self,
transform: &M,
dir: &Unit<P::Vector>,
_angle: P::Real,
out: &mut Vec<P>
)
impl<P: Point, M: Isometry<P>> Shape<P, M> for Ball<P::Real>
[src]
fn aabb(&self, m: &M) -> AABB<P>
[src]
fn bounding_sphere(&self, m: &M) -> BoundingSphere<P>
[src]
fn as_ray_cast(&self) -> Option<&dyn RayCast<P, M>>
[src]
fn as_point_query(&self) -> Option<&dyn PointQuery<P, M>>
[src]
fn as_support_map(&self) -> Option<&dyn SupportMap<P, M>>
[src]
fn is_support_map(&self) -> bool
[src]
fn as_composite_shape(&self) -> Option<&dyn CompositeShape<P, M>>
[src]
The composite shape representation of self
if applicable.
fn is_composite_shape(&self) -> bool
[src]
Whether self
uses a composite shape-based representation.
impl<P: Point, M: Isometry<P>> HasBoundingVolume<M, AABB<P>> for Ball<P::Real>
[src]
fn bounding_volume(&self, m: &M) -> AABB<P>
[src]
impl<P: Point, M: Isometry<P>> HasBoundingVolume<M, BoundingSphere<P>> for Ball<P::Real>
[src]
fn bounding_volume(&self, m: &M) -> BoundingSphere<P>
[src]
impl<P: Point, M: Isometry<P>> RayCast<P, M> for Ball<P::Real>
[src]
fn toi_with_ray(&self, m: &M, ray: &Ray<P>, solid: bool) -> Option<P::Real>
[src]
fn toi_and_normal_with_ray(
&self,
m: &M,
ray: &Ray<P>,
solid: bool
) -> Option<RayIntersection<P::Vector>>
[src]
&self,
m: &M,
ray: &Ray<P>,
solid: bool
) -> Option<RayIntersection<P::Vector>>
fn toi_and_normal_and_uv_with_ray(
&self,
m: &M,
ray: &Ray<P>,
solid: bool
) -> Option<RayIntersection<P::Vector>>
[src]
&self,
m: &M,
ray: &Ray<P>,
solid: bool
) -> Option<RayIntersection<P::Vector>>
fn intersects_ray(&self, m: &M, ray: &Ray<P>) -> bool
[src]
Tests whether a ray intersects this transformed shape.
impl<P: Point, M: Isometry<P>> PointQuery<P, M> for Ball<P::Real>
[src]
fn project_point(&self, m: &M, pt: &P, solid: bool) -> PointProjection<P>
[src]
fn distance_to_point(&self, m: &M, pt: &P, solid: bool) -> P::Real
[src]
fn contains_point(&self, m: &M, pt: &P) -> bool
[src]
impl<N: PartialEq> PartialEq<Ball<N>> for Ball<N>
[src]
impl<N: Clone> Clone for Ball<N>
[src]
fn clone(&self) -> Ball<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 Ball<N>
[src]
Auto Trait Implementations
Blanket Implementations
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T> From for T
[src]
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<SS, SP> SupersetOf for SP where
SS: SubsetOf<SP>,
[src]
SS: SubsetOf<SP>,
fn to_subset(&self) -> Option<SS>
[src]
fn is_in_subset(&self) -> bool
[src]
unsafe fn to_subset_unchecked(&self) -> SS
[src]
fn from_subset(element: &SS) -> SP
[src]
impl<T> Same for T
type Output = T
Should always be Self