Struct collide_capsule::Capsule[][src]

pub struct Capsule<V: VectorSpace> {
    pub start: V,
    pub end: V,
    pub rad: V::Scalar,
}
Expand description

The capsule collider defined as a convex hull around two spheres having the same radius.

Fields

start: V

The position of one sphere.

end: V

The position of the other sphere.

rad: V::Scalar

The radius of the spheres.

Implementations

Creates a new capsule collider.

Creates a new capsule collider representing a point.

Creates a new capsule collider representing a line.

Creates a new capsule collider representing a sphere.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

The vector type of this collider.

If both colliders collide, returns some collision info, else returns none.

Checks the collision between two colliders. Defaults to a check of the return value of collision info. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.