Struct mgf::Compound [] [src]

pub struct Compound {
    pub disp: Vector3<f32>,
    pub rot: Quaternion<f32>,
    pub shapes: Vec<Component>,
    pub bvh: BVH<AABB, usize>,
}

An aggregate structure of Spheres and Capsules. Has a position and rotation.

Fields

The displacement of the object.

The rotation of the object. Assumed to be normalized.

The geometries the compound is composed of.

BVH storing the bounds of the components to improve collision efficiency.

Methods

impl Compound
[src]

[src]

Trait Implementations

impl Clone for Compound
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

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

[src]

Performs the += operation.

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

[src]

Performs the -= operation.

impl BoundedBy<AABB> for Compound
[src]

[src]

impl BoundedBy<Sphere> for Compound
[src]

[src]

impl Shape for Compound
[src]

[src]

The point returned by a compound shape is the displacement of the object and not the center of mass. It is impossible for Compound to calculate the center of mass given it has no information regarding the mass of individual components.

[src]

Sets the center of the shape to p.

impl<RHS> Contacts<RHS> for Compound where
    RHS: Contacts<Component> + BoundedBy<AABB>, 
[src]

[src]

Calls the closure for each contact found. Returns true if any contact was found. Read more

[src]

Returns the last contact found, if one exists.