Enum mgf::Component[][src]

pub enum Component {
    Sphere(Sphere),
    Capsule(Capsule),
}

A component is a generic volume that can either be a Sphere or Capsule at runtime. Anything that can collide with a Sphere and a Capsule can collide with a component.

Variants

Methods

impl Component
[src]

Create a ComponentConstructor and return the position and rotation of the Component.

Trait Implementations

impl Copy for Component
[src]

impl Clone for Component
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

impl Debug for Component
[src]

Formats the value using the given formatter. Read more

impl Volumetric for Component
[src]

Rotate the bound in place. This is useless for spheres.

Rotates the object around a point.

impl From<Sphere> for Component
[src]

Performs the conversion.

impl From<Capsule> for Component
[src]

Performs the conversion.

impl Add<Vector3<f32>> for Component
[src]

The resulting type after applying the + operator.

Performs the + operation.

impl Sub<Vector3<f32>> for Component
[src]

The resulting type after applying the - operator.

Performs the - operation.

impl AddAssign<Vector3<f32>> for Component
[src]

Performs the += operation.

impl SubAssign<Vector3<f32>> for Component
[src]

Performs the -= operation.

impl Shape for Component
[src]

Returns the center of mass of the geometry, assuming a regular density.

Returns the closest point on the shape to the given point.

Sets the center of the shape to p.

impl BoundedBy<AABB> for Component
[src]

impl BoundedBy<Sphere> for Component
[src]

impl<P: Particle> Intersects<Component> for P
[src]

Returns an Intersection if one exists.

impl Inertia for Component
[src]

Auto Trait Implementations

impl Send for Component

impl Sync for Component