[][src]Enum nphysics3d::object::ColliderAnchor

pub enum ColliderAnchor<N: RealField, Handle: BodyHandle> {
    OnBodyPart {
        body_part: BodyPartHandle<Handle>,
        position_wrt_body_part: Isometry<N>,
    },
    OnDeformableBody {
        body: Handle,
        body_parts: Option<Arc<Vec<usize>>>,
    },
}

Description of the way a collider is attached to a body.

Variants

OnBodyPart

Attach of a collider with a body part.

Fields of OnBodyPart

body_part: BodyPartHandle<Handle>

The attached body part handle.

position_wrt_body_part: Isometry<N>

Relative position of the collider wrt. the body part.

OnDeformableBody

Attach of a collider with a deformable body.

Fields of OnDeformableBody

body: Handle

The attached body handle.

body_parts: Option<Arc<Vec<usize>>>

A map between the colliders parts and body part indices.

The i-th part of the collider corresponds to the body_parts[i]-th body part. If set to None, the mapping is trivial, i.e., i-th part of the collider corresponds to the i-th body part.

Methods

impl<N: RealField, Handle: BodyHandle> ColliderAnchor<N, Handle>[src]

pub fn body(&self) -> Handle[src]

The body this anchor is attached to.

Trait Implementations

impl<N: Clone + RealField, Handle: Clone + BodyHandle> Clone for ColliderAnchor<N, Handle>[src]

Auto Trait Implementations

impl<N, Handle> RefUnwindSafe for ColliderAnchor<N, Handle> where
    Handle: RefUnwindSafe,
    N: RefUnwindSafe + Scalar

impl<N, Handle> Send for ColliderAnchor<N, Handle> where
    N: Scalar

impl<N, Handle> Sync for ColliderAnchor<N, Handle> where
    N: Scalar

impl<N, Handle> Unpin for ColliderAnchor<N, Handle> where
    Handle: Unpin,
    N: Scalar + Unpin

impl<N, Handle> UnwindSafe for ColliderAnchor<N, Handle> where
    Handle: UnwindSafe,
    N: Scalar + UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Downcast for T where
    T: Any

impl<T> DowncastSync for T where
    T: Send + Sync + Any

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<SS, SP> SupersetOf<SS> for SP where
    SS: SubsetOf<SP>, 

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,