[][src]Struct nphysics2d::object::Multibody

pub struct Multibody<N: RealField> { /* fields omitted */ }

An articulated body simulated using the reduced-coordinates approach.

Methods

impl<N: RealField> Multibody<N>[src]

pub fn user_data(&self) -> Option<&(dyn Any + Send + Sync)>[src]

Retrieves a reference to the user-defined user-data attached to this object.

pub fn user_data_mut(&mut self) -> Option<&mut (dyn Any + Send + Sync)>[src]

Retrieves a mutable reference to the user-defined user-data attached to this object.

pub fn set_user_data(
    &mut self,
    data: Option<Box<dyn Any + Send + Sync>>
) -> Option<Box<dyn Any + Send + Sync>>
[src]

Sets the user-defined data attached to this object.

pub fn take_user_data(&mut self) -> Option<Box<dyn Any + Send + Sync>>[src]

Replace by None the user-defined data attached to this object and returns the old value.

pub fn root(&self) -> &MultibodyLink<N>[src]

The first link of this multibody.

pub fn root_mut(&mut self) -> &mut MultibodyLink<N>[src]

Mutable reference to the first link of this multibody.

Reference i-th multibody link of this multibody.

Return None if there is less than i + 1 multibody links.

Mutable reference to the multibody link with the given id.

Return None if the given id does not identifies a multibody link part of self.

The links of this multibody with the given name.

The number of links on this multibody.

Iterator through all the links of this multibody.

All link are guaranteed to be yielded before its descendant.

Mutable iterator through all the links of this multibody.

All link are guaranteed to be yielded before its descendant.

pub fn damping(&self) -> &DVector<N>[src]

The vector of damping applied to this multibody.

pub fn damping_mut(&mut self) -> &mut DVector<N>[src]

Mutable vector of damping applied to this multibody.

Set the mass of the specified link.

Set the angular inertia of the specified linked, expressed in its local space.

pub fn joint_velocity(&self, link: &MultibodyLink<N>) -> DVectorSlice<N>[src]

The generalized velocity at the joint of the given link.

Convert a force applied to the center of mass of the link rb_id into generalized force.

Convert a force applied to this multibody's link rb_id center of mass into generalized accelerations.

pub fn inv_mass_mul_unit_joint_force(
    &self,
    link: &MultibodyLink<N>,
    dof_id: usize,
    force: N,
    out: &mut [N]
)
[src]

Convert a generalized force applied to le link rb_id's degrees of freedom into generalized accelerations.

The joint attaching this link to its parent is assumed to be a unit joint.

pub fn inv_mass_mul_joint_force(
    &self,
    link: &MultibodyLink<N>,
    force: DVectorSlice<N>,
    out: &mut [N]
)
[src]

Convert a generalized force applied to the link rb_id's degrees of freedom into generalized accelerations.

pub fn augmented_mass(&self) -> &DMatrix<N>[src]

The augmented mass (inluding gyroscropic and coriolis terms) in world-space of this multibody.

pub fn joint_velocity_mut(&mut self, id: usize) -> DVectorSliceMut<N>[src]

Retrieve the mutable generalized velocities of this link.

pub fn generalized_force(&self) -> &DVector<N>[src]

The generalized forces applied to this multibody at the next timestep.

pub fn generalized_force_mut(&mut self) -> &mut DVector<N>[src]

Mutable reference to the generalized forces applied to this multibody at the next timestep.

Trait Implementations

impl<N: RealField> Body<N> for Multibody<N>[src]

Auto Trait Implementations

impl<N> !RefUnwindSafe for Multibody<N>

impl<N> Send for Multibody<N> where
    N: Scalar

impl<N> Sync for Multibody<N> where
    N: Scalar

impl<N> Unpin for Multibody<N> where
    N: Scalar + Unpin

impl<N> !UnwindSafe for Multibody<N>

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, 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>,