[−][src]Trait collision::Primitive
Minkowski support function for primitive
Associated Types
type Point: EuclideanSpace
Point type
Required methods
fn support_point<T>(
&self,
direction: &<Self::Point as EuclideanSpace>::Diff,
transform: &T
) -> Self::Point where
T: Transform<Self::Point>,
&self,
direction: &<Self::Point as EuclideanSpace>::Diff,
transform: &T
) -> Self::Point where
T: Transform<Self::Point>,
Get the support point on the shape in a given direction.
Parameters
direction
: The search direction in world space.transform
: The current local to world transform for this primitive.
Returns
Return the point that is furthest away from the origin, in the given search direction. For discrete shapes, the furthest vertex is enough, there is no need to do exact intersection point computation.
Type parameters
P
: Transform type
Implementations on Foreign Types
impl<B, P> Primitive for (P, B) where
P: Primitive,
B: Bound,
[src]
impl<B, P> Primitive for (P, B) where
P: Primitive,
B: Bound,
type Point = P::Point
fn support_point<T>( | [src] |
Implementors
impl<S> Primitive for Primitive2<S> where
S: BaseFloat,
[src]
impl<S> Primitive for Primitive2<S> where
S: BaseFloat,
type Point = Point2<S>
fn support_point<T>(&self, direction: &Vector2<S>, transform: &T) -> Point2<S> where | [src] |
impl<S> Primitive for Primitive3<S> where
S: BaseFloat,
[src]
impl<S> Primitive for Primitive3<S> where
S: BaseFloat,
type Point = Point3<S>
fn support_point<T>(&self, direction: &Vector3<S>, transform: &T) -> Point3<S> where | [src] |
impl<S> Primitive for Capsule<S> where
S: BaseFloat,
[src]
impl<S> Primitive for Capsule<S> where
S: BaseFloat,
type Point = Point3<S>
fn support_point<T>(&self, direction: &Vector3<S>, transform: &T) -> Point3<S> where | [src] |
impl<S> Primitive for Circle<S> where
S: BaseFloat,
[src]
impl<S> Primitive for Circle<S> where
S: BaseFloat,
type Point = Point2<S>
fn support_point<T>(&self, direction: &Vector2<S>, transform: &T) -> Point2<S> where | [src] |
impl<S> Primitive for ConvexPolygon<S> where
S: BaseFloat,
[src]
impl<S> Primitive for ConvexPolygon<S> where
S: BaseFloat,
type Point = Point2<S>
fn support_point<T>(&self, direction: &Vector2<S>, transform: &T) -> Point2<S> where | [src] |
impl<S> Primitive for ConvexPolyhedron<S> where
S: BaseFloat,
[src]
impl<S> Primitive for ConvexPolyhedron<S> where
S: BaseFloat,
type Point = Point3<S>
fn support_point<T>(&self, direction: &Vector3<S>, transform: &T) -> Point3<S> where | [src] |
impl<S> Primitive for Cube<S> where
S: BaseFloat,
[src]
impl<S> Primitive for Cube<S> where
S: BaseFloat,
type Point = Point3<S>
fn support_point<T>(&self, direction: &Vector3<S>, transform: &T) -> Point3<S> where | [src] |
impl<S> Primitive for Cuboid<S> where
S: BaseFloat,
[src]
impl<S> Primitive for Cuboid<S> where
S: BaseFloat,
type Point = Point3<S>
fn support_point<T>(&self, direction: &Vector3<S>, transform: &T) -> Point3<S> where | [src] |
impl<S> Primitive for Cylinder<S> where
S: BaseFloat,
[src]
impl<S> Primitive for Cylinder<S> where
S: BaseFloat,
type Point = Point3<S>
fn support_point<T>(&self, direction: &Vector3<S>, transform: &T) -> Point3<S> where | [src] |
impl<S> Primitive for Quad<S> where
S: BaseFloat,
[src]
impl<S> Primitive for Quad<S> where
S: BaseFloat,
type Point = Point3<S>
fn support_point<T>(&self, direction: &Vector3<S>, transform: &T) -> Point3<S> where | [src] |
impl<S> Primitive for Rectangle<S> where
S: BaseFloat,
[src]
impl<S> Primitive for Rectangle<S> where
S: BaseFloat,
type Point = Point2<S>
fn support_point<T>(&self, direction: &Vector2<S>, transform: &T) -> Point2<S> where | [src] |
impl<S> Primitive for Sphere<S> where
S: BaseFloat,
[src]
impl<S> Primitive for Sphere<S> where
S: BaseFloat,
type Point = Point3<S>
fn support_point<T>(&self, direction: &Vector3<S>, transform: &T) -> Point3<S> where | [src] |
impl<S> Primitive for Square<S> where
S: BaseFloat,
[src]
impl<S> Primitive for Square<S> where
S: BaseFloat,
type Point = Point2<S>
fn support_point<T>(&self, direction: &Vector2<S>, transform: &T) -> Point2<S> where | [src] |
impl<S> Primitive for Line2<S> where
S: BaseFloat,
[src]
impl<S> Primitive for Line2<S> where
S: BaseFloat,