Bullet Collision Detection & Physics Library: btMultiBody Class Reference

Bullet Collision Detection & Physics Library

Public Member Functions | Static Public Member Functions | Private Member Functions | Private Attributes | List of all members
btMultiBody Class Reference

`#include <btMultiBody.h>`

Collaboration diagram for btMultiBody:
[legend]

## Public Member Functions
| BT_DECLARE_ALIGNED_ALLOCATOR ()
| btMultiBody (int n_links, btScalar mass, const btVector3 &inertia, bool fixedBase, bool canSleep, bool deprecatedMultiDof=true)
virtual | ~btMultiBody ()
void | setupFixed (int linkIndex, btScalar mass, const btVector3 &inertia, int parent, const btQuaternion &rotParentToThis, const btVector3 &parentComToThisPivotOffset, const btVector3 &thisPivotToThisComOffset, bool deprecatedDisableParentCollision=true)
void | setupPrismatic (int i, btScalar mass, const btVector3 &inertia, int parent, const btQuaternion &rotParentToThis, const btVector3 &jointAxis, const btVector3 &parentComToThisPivotOffset, const btVector3 &thisPivotToThisComOffset, bool disableParentCollision)
void | setupRevolute (int linkIndex, btScalar mass, const btVector3 &inertia, int parentIndex, const btQuaternion &rotParentToThis, const btVector3 &jointAxis, const btVector3 &parentComToThisPivotOffset, const btVector3 &thisPivotToThisComOffset, bool disableParentCollision=false)
void | setupSpherical (int linkIndex, btScalar mass, const btVector3 &inertia, int parent, const btQuaternion &rotParentToThis, const btVector3 &parentComToThisPivotOffset, const btVector3 &thisPivotToThisComOffset, bool disableParentCollision=false)
void | setupPlanar (int i, btScalar mass, const btVector3 &inertia, int parent, const btQuaternion &rotParentToThis, const btVector3 &rotationAxis, const btVector3 &parentComToThisComOffset, bool disableParentCollision=false)
const btMultibodyLink & | getLink (int index) const
btMultibodyLink & | getLink (int index)
void | setBaseCollider (btMultiBodyLinkCollider *collider)
const btMultiBodyLinkCollider * | getBaseCollider () const
btMultiBodyLinkCollider * | getBaseCollider ()
const btMultiBodyLinkCollider * | getLinkCollider (int index) const
btMultiBodyLinkCollider * | getLinkCollider (int index)
int | getParent (int link_num) const
int | getNumLinks () const
int | getNumDofs () const
int | getNumPosVars () const
btScalar | getBaseMass () const
const btVector3 & | getBaseInertia () const
btScalar | getLinkMass (int i) const
const btVector3 & | getLinkInertia (int i) const
void | setBaseMass (btScalar mass)
void | setBaseInertia (const btVector3 &inertia)
const btVector3 & | getBasePos () const
const btVector3 | getBaseVel () const
const btQuaternion & | getWorldToBaseRot () const
btVector3 | getBaseOmega () const
void | setBasePos (const btVector3 &pos)
void | setBaseWorldTransform (const btTransform &tr)
btTransform | getBaseWorldTransform () const
void | setBaseVel (const btVector3 &vel)
void | setWorldToBaseRot (const btQuaternion &rot)
void | setBaseOmega (const btVector3 &omega)
btScalar | getJointPos (int i) const
btScalar | getJointVel (int i) const
btScalar * | getJointVelMultiDof (int i)
btScalar * | getJointPosMultiDof (int i)
const btScalar * | getJointVelMultiDof (int i) const
const btScalar * | getJointPosMultiDof (int i) const
void | setJointPos (int i, btScalar q)
void | setJointVel (int i, btScalar qdot)
void | setJointPosMultiDof (int i, const double *q)
void | setJointVelMultiDof (int i, const double *qdot)
void | setJointPosMultiDof (int i, const float *q)
void | setJointVelMultiDof (int i, const float *qdot)
const btScalar * | getVelocityVector () const
const btVector3 & | getRVector (int i) const
const btQuaternion & | getParentToLocalRot (int i) const
btVector3 | localPosToWorld (int i, const btVector3 &vec) const
btVector3 | localDirToWorld (int i, const btVector3 &vec) const
btVector3 | worldPosToLocal (int i, const btVector3 &vec) const
btVector3 | worldDirToLocal (int i, const btVector3 &vec) const
btMatrix3x3 | localFrameToWorld (int i, const btMatrix3x3 &mat) const
btScalar | getKineticEnergy () const
btVector3 | getAngularMomentum () const
void | clearForcesAndTorques ()
void | clearConstraintForces ()
void | clearVelocities ()
void | addBaseForce (const btVector3 &f)
void | addBaseTorque (const btVector3 &t)
void | addLinkForce (int i, const btVector3 &f)
void | addLinkTorque (int i, const btVector3 &t)
void | addBaseConstraintForce (const btVector3 &f)
void | addBaseConstraintTorque (const btVector3 &t)
void | addLinkConstraintForce (int i, const btVector3 &f)
void | addLinkConstraintTorque (int i, const btVector3 &t)
void | addJointTorque (int i, btScalar Q)
void | addJointTorqueMultiDof (int i, int dof, btScalar Q)
void | addJointTorqueMultiDof (int i, const btScalar *Q)
const btVector3 & | getBaseForce () const
const btVector3 & | getBaseTorque () const
const btVector3 & | getLinkForce (int i) const
const btVector3 & | getLinkTorque (int i) const
btScalar | getJointTorque (int i) const
btScalar * | getJointTorqueMultiDof (int i)
void | computeAccelerationsArticulatedBodyAlgorithmMultiDof (btScalar dt, btAlignedObjectArray< btScalar > &scratch_r, btAlignedObjectArray< btVector3 > &scratch_v, btAlignedObjectArray< btMatrix3x3 > &scratch_m, bool isConstraintPass, bool jointFeedbackInWorldSpace, bool jointFeedbackInJointFrame)
void | calcAccelerationDeltasMultiDof (const btScalar *force, btScalar *output, btAlignedObjectArray< btScalar > &scratch_r, btAlignedObjectArray< btVector3 > &scratch_v) const
| stepVelocitiesMultiDof is deprecated, use computeAccelerationsArticulatedBodyAlgorithmMultiDof instead More...
void | applyDeltaVeeMultiDof2 (const btScalar *delta_vee, btScalar multiplier)
void | processDeltaVeeMultiDof2 ()
void | applyDeltaVeeMultiDof (const btScalar *delta_vee, btScalar multiplier)
void | stepPositionsMultiDof (btScalar dt, btScalar *pq=0, btScalar *pqd=0)
void | fillContactJacobianMultiDof (int link, const btVector3 &contact_point, const btVector3 &normal, btScalar *jac, btAlignedObjectArray< btScalar > &scratch_r, btAlignedObjectArray< btVector3 > &scratch_v, btAlignedObjectArray< btMatrix3x3 > &scratch_m) const
void | fillConstraintJacobianMultiDof (int link, const btVector3 &contact_point, const btVector3 &normal_ang, const btVector3 &normal_lin, btScalar *jac, btAlignedObjectArray< btScalar > &scratch_r, btAlignedObjectArray< btVector3 > &scratch_v, btAlignedObjectArray< btMatrix3x3 > &scratch_m) const
void | setCanSleep (bool canSleep)
bool | getCanSleep () const
bool | isAwake () const
void | wakeUp ()
void | goToSleep ()
void | checkMotionAndSleepIfRequired (btScalar timestep)
bool | hasFixedBase () const
int | getCompanionId () const
void | setCompanionId (int id)
void | setNumLinks (int numLinks)
btScalar | getLinearDamping () const
void | setLinearDamping (btScalar damp)
btScalar | getAngularDamping () const
void | setAngularDamping (btScalar damp)
bool | getUseGyroTerm () const
void | setUseGyroTerm (bool useGyro)
btScalar | getMaxCoordinateVelocity () const
void | setMaxCoordinateVelocity (btScalar maxVel)
btScalar | getMaxAppliedImpulse () const
void | setMaxAppliedImpulse (btScalar maxImp)
void | setHasSelfCollision (bool hasSelfCollision)
bool | hasSelfCollision () const
void | finalizeMultiDof ()
void | useRK4Integration (bool use)
bool | isUsingRK4Integration () const
void | useGlobalVelocities (bool use)
bool | isUsingGlobalVelocities () const
bool | isPosUpdated () const
void | setPosUpdated (bool updated)
bool | internalNeedsJointFeedback () const
void | forwardKinematics (btAlignedObjectArray< btQuaternion > &scratch_q, btAlignedObjectArray< btVector3 > &scratch_m)
void | compTreeLinkVelocities (btVector3 *omega, btVector3 *vel) const
void | updateCollisionObjectWorldTransforms (btAlignedObjectArray< btQuaternion > &scratch_q, btAlignedObjectArray< btVector3 > &scratch_m)
virtual int | calculateSerializeBufferSize () const
virtual const char * | serialize (void *dataBuffer, class btSerializer *serializer) const
| fills the dataBuffer and returns the struct name (and 0 on failure) More...
const char * | getBaseName () const
void | setBaseName (const char *name)
| memory of setBaseName needs to be manager by user More...
void * | getUserPointer () const
| users can point to their objects, userPointer is not used by Bullet More...
int | getUserIndex () const
int | getUserIndex2 () const
void | setUserPointer (void *userPointer)
| users can point to their objects, userPointer is not used by Bullet More...
void | setUserIndex (int index)
| users can point to their objects, userPointer is not used by Bullet More...
void | setUserIndex2 (int index)

## Static Public Member Functions
static void | spatialTransform (const btMatrix3x3 &rotation_matrix, const btVector3 &displacement, const btVector3 &top_in, const btVector3 &bottom_in, btVector3 &top_out, btVector3 &bottom_out)

## Private Member Functions
| btMultiBody (const btMultiBody &)
void | operator= (const btMultiBody &)
void | solveImatrix (const btVector3 &rhs_top, const btVector3 &rhs_bot, btScalar result[6]) const
void | solveImatrix (const btSpatialForceVector &rhs, btSpatialMotionVector &result) const
void | updateLinksDofOffsets ()
void | mulMatrix (btScalar *pA, btScalar *pB, int rowsA, int colsA, int rowsB, int colsB, btScalar *pC) const

## Private Attributes
btMultiBodyLinkCollider * | m_baseCollider
const char * | m_baseName
btVector3 | m_basePos
btQuaternion | m_baseQuat
btScalar | m_baseMass
btVector3 | m_baseInertia
btVector3 | m_baseForce
btVector3 | m_baseTorque
btVector3 | m_baseConstraintForce
btVector3 | m_baseConstraintTorque
btAlignedObjectArray< btMultibodyLink > | m_links
btAlignedObjectArray< btScalar > | m_deltaV
btAlignedObjectArray< btScalar > | m_realBuf
btAlignedObjectArray< btVector3 > | m_vectorBuf
btAlignedObjectArray< btMatrix3x3 > | m_matrixBuf
btMatrix3x3 | m_cachedInertiaTopLeft
btMatrix3x3 | m_cachedInertiaTopRight
btMatrix3x3 | m_cachedInertiaLowerLeft
btMatrix3x3 | m_cachedInertiaLowerRight
bool | m_cachedInertiaValid
bool | m_fixedBase
bool | m_awake
bool | m_canSleep
btScalar | m_sleepTimer
void * | m_userObjectPointer
int | m_userIndex2
int | m_userIndex
int | m_companionId
btScalar | m_linearDamping
btScalar | m_angularDamping
bool | m_useGyroTerm
btScalar | m_maxAppliedImpulse
btScalar | m_maxCoordinateVelocity
bool | m_hasSelfCollision
bool | __posUpdated
int | m_dofCount
int | m_posVarCnt
bool | m_useRK4
bool | m_useGlobalVelocities
bool | m_internalNeedsJointFeedback
| the m_needsJointFeedback gets updated/computed during the stepVelocitiesMultiDof and it for internal usage only More...

## Detailed Description

Definition at line 49 of file btMultiBody.h.

## Constructor & Destructor Documentation

## ◆ btMultiBody() [1/2]

btMultiBody::btMultiBody | ( | int | n_links,
|  | btScalar | mass,
|  | const btVector3 & | inertia,
|  | bool | fixedBase,
|  | bool | canSleep,
|  | bool | deprecatedMultiDof = `true`
| ) |  |

Definition at line 93 of file btMultiBody.cpp.

## ◆ ~btMultiBody()

btMultiBody::~btMultiBody | ( |  | ) |
| virtual

Definition at line 143 of file btMultiBody.cpp.

## ◆ btMultiBody() [2/2]

btMultiBody::btMultiBody | ( | const btMultiBody & |  | ) |
| private

## Member Function Documentation

## ◆ addBaseConstraintForce()

void btMultiBody::addBaseConstraintForce | ( | const btVector3 & | f | ) |
| inline

Definition at line 312 of file btMultiBody.h.

## ◆ addBaseConstraintTorque()

void btMultiBody::addBaseConstraintTorque | ( | const btVector3 & | t | ) |
| inline

Definition at line 316 of file btMultiBody.h.

## ◆ addBaseForce()

void btMultiBody::addBaseForce | ( | const btVector3 & | f | ) |
| inline

Definition at line 304 of file btMultiBody.h.

## ◆ addBaseTorque()

void btMultiBody::addBaseTorque | ( | const btVector3 & | t | ) |
| inline

Definition at line 308 of file btMultiBody.h.

## ◆ addJointTorque()

void btMultiBody::addJointTorque | ( | int | i,
|  | btScalar | Q
| ) |  |

Definition at line 670 of file btMultiBody.cpp.

## ◆ addJointTorqueMultiDof() [1/2]

void btMultiBody::addJointTorqueMultiDof | ( | int | i,
|  | int | dof,
|  | btScalar | Q
| ) |  |

Definition at line 675 of file btMultiBody.cpp.

## ◆ addJointTorqueMultiDof() [2/2]

void btMultiBody::addJointTorqueMultiDof | ( | int | i,
|  | const btScalar * | Q
| ) |  |

Definition at line 680 of file btMultiBody.cpp.

## ◆ addLinkConstraintForce()

void btMultiBody::addLinkConstraintForce | ( | int | i,
|  | const btVector3 & | f
| ) |  |

Definition at line 660 of file btMultiBody.cpp.

## ◆ addLinkConstraintTorque()

void btMultiBody::addLinkConstraintTorque | ( | int | i,
|  | const btVector3 & | t
| ) |  |

Definition at line 665 of file btMultiBody.cpp.

## ◆ addLinkForce()

void btMultiBody::addLinkForce | ( | int | i,
|  | const btVector3 & | f
| ) |  |

Definition at line 650 of file btMultiBody.cpp.

## ◆ addLinkTorque()

void btMultiBody::addLinkTorque | ( | int | i,
|  | const btVector3 & | t
| ) |  |

Definition at line 655 of file btMultiBody.cpp.

## ◆ applyDeltaVeeMultiDof()

void btMultiBody::applyDeltaVeeMultiDof | ( | const btScalar * | delta_vee,
|  | btScalar | multiplier
| ) |  |
| inline

Definition at line 394 of file btMultiBody.h.

## ◆ applyDeltaVeeMultiDof2()

void btMultiBody::applyDeltaVeeMultiDof2 | ( | const btScalar * | delta_vee,
|  | btScalar | multiplier
| ) |  |
| inline

Definition at line 377 of file btMultiBody.h.

## ◆ BT_DECLARE_ALIGNED_ALLOCATOR()

btMultiBody::BT_DECLARE_ALIGNED_ALLOCATOR | ( |  | ) |

## ◆ calcAccelerationDeltasMultiDof()

void btMultiBody::calcAccelerationDeltasMultiDof | ( | const btScalar * | force,
|  | btScalar * | output,
|  | btAlignedObjectArray< btScalar > & | scratch_r,
|  | btAlignedObjectArray< btVector3 > & | scratch_v
| ) |  | const

stepVelocitiesMultiDof is deprecated, use computeAccelerationsArticulatedBodyAlgorithmMultiDof instead

Definition at line 1424 of file btMultiBody.cpp.

## ◆ calculateSerializeBufferSize()

int btMultiBody::calculateSerializeBufferSize | ( |  | ) | const
| virtual

Definition at line 2002 of file btMultiBody.cpp.

## ◆ checkMotionAndSleepIfRequired()

void btMultiBody::checkMotionAndSleepIfRequired | ( | btScalar | timestep | ) |

Definition at line 1875 of file btMultiBody.cpp.

## ◆ clearConstraintForces()

void btMultiBody::clearConstraintForces | ( |  | ) |

Definition at line 619 of file btMultiBody.cpp.

## ◆ clearForcesAndTorques()

void btMultiBody::clearForcesAndTorques | ( |  | ) |

Definition at line 630 of file btMultiBody.cpp.

## ◆ clearVelocities()

void btMultiBody::clearVelocities | ( |  | ) |

Definition at line 643 of file btMultiBody.cpp.

## ◆ compTreeLinkVelocities()

void btMultiBody::compTreeLinkVelocities | ( | btVector3 * | omega,
|  | btVector3 * | vel
| ) |  | const

Definition at line 544 of file btMultiBody.cpp.

## ◆ computeAccelerationsArticulatedBodyAlgorithmMultiDof()

void btMultiBody::computeAccelerationsArticulatedBodyAlgorithmMultiDof | ( | btScalar | dt,
|  | btAlignedObjectArray< btScalar > & | scratch_r,
|  | btAlignedObjectArray< btVector3 > & | scratch_v,
|  | btAlignedObjectArray< btMatrix3x3 > & | scratch_m,
|  | bool | isConstraintPass,
|  | bool | jointFeedbackInWorldSpace,
|  | bool | jointFeedbackInJointFrame
| ) |  |

Definition at line 730 of file btMultiBody.cpp.

## ◆ fillConstraintJacobianMultiDof()

void btMultiBody::fillConstraintJacobianMultiDof | ( | int | link,
|  | const btVector3 & | contact_point,
|  | const btVector3 & | normal_ang,
|  | const btVector3 & | normal_lin,
|  | btScalar * | jac,
|  | btAlignedObjectArray< btScalar > & | scratch_r,
|  | btAlignedObjectArray< btVector3 > & | scratch_v,
|  | btAlignedObjectArray< btMatrix3x3 > & | scratch_m
| ) |  | const

Definition at line 1721 of file btMultiBody.cpp.

## ◆ fillContactJacobianMultiDof()

void btMultiBody::fillContactJacobianMultiDof | ( | int | link,
|  | const btVector3 & | contact_point,
|  | const btVector3 & | normal,
|  | btScalar * | jac,
|  | btAlignedObjectArray< btScalar > & | scratch_r,
|  | btAlignedObjectArray< btVector3 > & | scratch_v,
|  | btAlignedObjectArray< btMatrix3x3 > & | scratch_m
| ) |  | const
| inline

Definition at line 430 of file btMultiBody.h.

## ◆ finalizeMultiDof()

void btMultiBody::finalizeMultiDof | ( |  | ) |

Definition at line 340 of file btMultiBody.cpp.

## ◆ forwardKinematics()

void btMultiBody::forwardKinematics | ( | btAlignedObjectArray< btQuaternion > & | scratch_q,
|  | btAlignedObjectArray< btVector3 > & | scratch_m
| ) |  |

base + num m_links

Definition at line 1908 of file btMultiBody.cpp.

## ◆ getAngularDamping()

btScalar btMultiBody::getAngularDamping | ( |  | ) | const
| inline

Definition at line 495 of file btMultiBody.h.

## ◆ getAngularMomentum()

btVector3 btMultiBody::getAngularMomentum | ( |  | ) | const

Definition at line 595 of file btMultiBody.cpp.

## ◆ getBaseCollider() [1/2]

const btMultiBodyLinkCollider* btMultiBody::getBaseCollider | ( |  | ) | const
| inline

Definition at line 128 of file btMultiBody.h.

## ◆ getBaseCollider() [2/2]

btMultiBodyLinkCollider* btMultiBody::getBaseCollider | ( |  | ) |
| inline

Definition at line 132 of file btMultiBody.h.

## ◆ getBaseForce()

const btVector3& btMultiBody::getBaseForce | ( |  | ) | const
| inline

Definition at line 324 of file btMultiBody.h.

## ◆ getBaseInertia()

const btVector3& btMultiBody::getBaseInertia | ( |  | ) | const
| inline

Definition at line 170 of file btMultiBody.h.

## ◆ getBaseMass()

btScalar btMultiBody::getBaseMass | ( |  | ) | const
| inline

Definition at line 169 of file btMultiBody.h.

## ◆ getBaseName()

const char* btMultiBody::getBaseName | ( |  | ) | const
| inline

Definition at line 570 of file btMultiBody.h.

## ◆ getBaseOmega()

btVector3 btMultiBody::getBaseOmega | ( |  | ) | const
| inline

Definition at line 194 of file btMultiBody.h.

## ◆ getBasePos()

const btVector3& btMultiBody::getBasePos | ( |  | ) | const
| inline

Definition at line 185 of file btMultiBody.h.

## ◆ getBaseTorque()

const btVector3& btMultiBody::getBaseTorque | ( |  | ) | const
| inline

Definition at line 325 of file btMultiBody.h.

## ◆ getBaseVel()

const btVector3 btMultiBody::getBaseVel | ( |  | ) | const
| inline

Definition at line 186 of file btMultiBody.h.

## ◆ getBaseWorldTransform()

btTransform btMultiBody::getBaseWorldTransform | ( |  | ) | const
| inline

Definition at line 207 of file btMultiBody.h.

## ◆ getCanSleep()

bool btMultiBody::getCanSleep | ( |  | ) | const
| inline

Definition at line 457 of file btMultiBody.h.

## ◆ getCompanionId()

int btMultiBody::getCompanionId | ( |  | ) | const
| inline

Definition at line 472 of file btMultiBody.h.

## ◆ getJointPos()

btScalar btMultiBody::getJointPos | ( | int | i | ) | const

Definition at line 368 of file btMultiBody.cpp.

## ◆ getJointPosMultiDof() [1/2]

btScalar * btMultiBody::getJointPosMultiDof | ( | int | i | ) |

Definition at line 378 of file btMultiBody.cpp.

## ◆ getJointPosMultiDof() [2/2]

const btScalar * btMultiBody::getJointPosMultiDof | ( | int | i | ) | const

Definition at line 388 of file btMultiBody.cpp.

## ◆ getJointTorque()

btScalar btMultiBody::getJointTorque | ( | int | i | ) | const

Definition at line 696 of file btMultiBody.cpp.

## ◆ getJointTorqueMultiDof()

btScalar * btMultiBody::getJointTorqueMultiDof | ( | int | i | ) |

Definition at line 701 of file btMultiBody.cpp.

## ◆ getJointVel()

btScalar btMultiBody::getJointVel | ( | int | i | ) | const

Definition at line 373 of file btMultiBody.cpp.

## ◆ getJointVelMultiDof() [1/2]

btScalar * btMultiBody::getJointVelMultiDof | ( | int | i | ) |

Definition at line 383 of file btMultiBody.cpp.

## ◆ getJointVelMultiDof() [2/2]

const btScalar * btMultiBody::getJointVelMultiDof | ( | int | i | ) | const

Definition at line 393 of file btMultiBody.cpp.

## ◆ getKineticEnergy()

btScalar btMultiBody::getKineticEnergy | ( |  | ) | const

Definition at line 572 of file btMultiBody.cpp.

## ◆ getLinearDamping()

btScalar btMultiBody::getLinearDamping | ( |  | ) | const
| inline

Definition at line 487 of file btMultiBody.h.

## ◆ getLink() [1/2]

const btMultibodyLink& btMultiBody::getLink | ( | int | index | ) | const
| inline

Definition at line 114 of file btMultiBody.h.

## ◆ getLink() [2/2]

btMultibodyLink& btMultiBody::getLink | ( | int | index | ) |
| inline

Definition at line 119 of file btMultiBody.h.

## ◆ getLinkCollider() [1/2]

const btMultiBodyLinkCollider* btMultiBody::getLinkCollider | ( | int | index | ) | const
| inline

Definition at line 137 of file btMultiBody.h.

## ◆ getLinkCollider() [2/2]

btMultiBodyLinkCollider* btMultiBody::getLinkCollider | ( | int | index | ) |
| inline

Definition at line 146 of file btMultiBody.h.

## ◆ getLinkForce()

const btVector3 & btMultiBody::getLinkForce | ( | int | i | ) | const

Definition at line 686 of file btMultiBody.cpp.

## ◆ getLinkInertia()

const btVector3 & btMultiBody::getLinkInertia | ( | int | i | ) | const

Definition at line 363 of file btMultiBody.cpp.

## ◆ getLinkMass()

btScalar btMultiBody::getLinkMass | ( | int | i | ) | const

Definition at line 358 of file btMultiBody.cpp.

## ◆ getLinkTorque()

const btVector3 & btMultiBody::getLinkTorque | ( | int | i | ) | const

Definition at line 691 of file btMultiBody.cpp.

## ◆ getMaxAppliedImpulse()

btScalar btMultiBody::getMaxAppliedImpulse | ( |  | ) | const
| inline

Definition at line 521 of file btMultiBody.h.

## ◆ getMaxCoordinateVelocity()

btScalar btMultiBody::getMaxCoordinateVelocity | ( |  | ) | const
| inline

Definition at line 512 of file btMultiBody.h.

## ◆ getNumDofs()

int btMultiBody::getNumDofs | ( |  | ) | const
| inline

Definition at line 167 of file btMultiBody.h.

## ◆ getNumLinks()

int btMultiBody::getNumLinks | ( |  | ) | const
| inline

Definition at line 166 of file btMultiBody.h.

## ◆ getNumPosVars()

int btMultiBody::getNumPosVars | ( |  | ) | const
| inline

Definition at line 168 of file btMultiBody.h.

## ◆ getParent()

int btMultiBody::getParent | ( | int | link_num | ) | const

Definition at line 353 of file btMultiBody.cpp.

## ◆ getParentToLocalRot()

const btQuaternion & btMultiBody::getParentToLocalRot | ( | int | i | ) | const

Definition at line 445 of file btMultiBody.cpp.

## ◆ getRVector()

const btVector3 & btMultiBody::getRVector | ( | int | i | ) | const

Definition at line 440 of file btMultiBody.cpp.

## ◆ getUseGyroTerm()

bool btMultiBody::getUseGyroTerm | ( |  | ) | const
| inline

Definition at line 504 of file btMultiBody.h.

## ◆ getUserIndex()

int btMultiBody::getUserIndex | ( |  | ) | const
| inline

Definition at line 586 of file btMultiBody.h.

## ◆ getUserIndex2()

int btMultiBody::getUserIndex2 | ( |  | ) | const
| inline

Definition at line 591 of file btMultiBody.h.

## ◆ getUserPointer()

void* btMultiBody::getUserPointer | ( |  | ) | const
| inline

users can point to their objects, userPointer is not used by Bullet

Definition at line 581 of file btMultiBody.h.

## ◆ getVelocityVector()

const btScalar* btMultiBody::getVelocityVector | ( |  | ) | const
| inline

Definition at line 256 of file btMultiBody.h.

## ◆ getWorldToBaseRot()

const btQuaternion& btMultiBody::getWorldToBaseRot | ( |  | ) | const
| inline

Definition at line 190 of file btMultiBody.h.

## ◆ goToSleep()

void btMultiBody::goToSleep | ( |  | ) |

Definition at line 1870 of file btMultiBody.cpp.

## ◆ hasFixedBase()

bool btMultiBody::hasFixedBase | ( |  | ) | const
| inline

Definition at line 467 of file btMultiBody.h.

## ◆ hasSelfCollision()

bool btMultiBody::hasSelfCollision | ( |  | ) | const
| inline

Definition at line 533 of file btMultiBody.h.

## ◆ internalNeedsJointFeedback()

bool btMultiBody::internalNeedsJointFeedback | ( |  | ) | const
| inline

Definition at line 555 of file btMultiBody.h.

## ◆ isAwake()

bool btMultiBody::isAwake | ( |  | ) | const
| inline

Definition at line 462 of file btMultiBody.h.

## ◆ isPosUpdated()

bool btMultiBody::isPosUpdated | ( |  | ) | const
| inline

Definition at line 545 of file btMultiBody.h.

## ◆ isUsingGlobalVelocities()

bool btMultiBody::isUsingGlobalVelocities | ( |  | ) | const
| inline

Definition at line 543 of file btMultiBody.h.

## ◆ isUsingRK4Integration()

bool btMultiBody::isUsingRK4Integration | ( |  | ) | const
| inline

Definition at line 541 of file btMultiBody.h.

## ◆ localDirToWorld()

btVector3 btMultiBody::localDirToWorld | ( | int | i,
|  | const btVector3 & | vec
| ) |  | const

Definition at line 496 of file btMultiBody.cpp.

## ◆ localFrameToWorld()

btMatrix3x3 btMultiBody::localFrameToWorld | ( | int | i,
|  | const btMatrix3x3 & | mat
| ) |  | const

Definition at line 534 of file btMultiBody.cpp.

## ◆ localPosToWorld()

btVector3 btMultiBody::localPosToWorld | ( | int | i,
|  | const btVector3 & | vec
| ) |  | const

Definition at line 450 of file btMultiBody.cpp.

## ◆ mulMatrix()

void btMultiBody::mulMatrix | ( | btScalar * | pA,
|  | btScalar * | pB,
|  | int | rowsA,
|  | int | colsA,
|  | int | rowsB,
|  | int | colsB,
|  | btScalar * | pC
| ) |  | const
| private

Definition at line 1409 of file btMultiBody.cpp.

## ◆ operator=()

void btMultiBody::operator= | ( | const btMultiBody & |  | ) |
| private

## ◆ processDeltaVeeMultiDof2()

void btMultiBody::processDeltaVeeMultiDof2 | ( |  | ) |
| inline

Definition at line 384 of file btMultiBody.h.

## ◆ serialize()

const char * btMultiBody::serialize | ( | void * | dataBuffer,
|  | class btSerializer * | serializer
| ) |  | const
| virtual

fills the dataBuffer and returns the struct name (and 0 on failure)

Definition at line 2009 of file btMultiBody.cpp.

## ◆ setAngularDamping()

void btMultiBody::setAngularDamping | ( | btScalar | damp | ) |
| inline

Definition at line 499 of file btMultiBody.h.

## ◆ setBaseCollider()

void btMultiBody::setBaseCollider | ( | btMultiBodyLinkCollider * | collider | ) |
| inline

Definition at line 124 of file btMultiBody.h.

## ◆ setBaseInertia()

void btMultiBody::setBaseInertia | ( | const btVector3 & | inertia | ) |
| inline

Definition at line 179 of file btMultiBody.h.

## ◆ setBaseMass()

void btMultiBody::setBaseMass | ( | btScalar | mass | ) |
| inline

Definition at line 178 of file btMultiBody.h.

## ◆ setBaseName()

void btMultiBody::setBaseName | ( | const char * | name | ) |
| inline

memory of setBaseName needs to be manager by user

Definition at line 575 of file btMultiBody.h.

## ◆ setBaseOmega()

void btMultiBody::setBaseOmega | ( | const btVector3 & | omega | ) |
| inline

Definition at line 225 of file btMultiBody.h.

## ◆ setBasePos()

void btMultiBody::setBasePos | ( | const btVector3 & | pos | ) |
| inline

Definition at line 196 of file btMultiBody.h.

## ◆ setBaseVel()

void btMultiBody::setBaseVel | ( | const btVector3 & | vel | ) |
| inline

Definition at line 215 of file btMultiBody.h.

## ◆ setBaseWorldTransform()

void btMultiBody::setBaseWorldTransform | ( | const btTransform & | tr | ) |
| inline

Definition at line 201 of file btMultiBody.h.

## ◆ setCanSleep()

void btMultiBody::setCanSleep | ( | bool | canSleep | ) |
| inline

Definition at line 452 of file btMultiBody.h.

## ◆ setCompanionId()

void btMultiBody::setCompanionId | ( | int | id | ) |
| inline

Definition at line 476 of file btMultiBody.h.

## ◆ setHasSelfCollision()

void btMultiBody::setHasSelfCollision | ( | bool | hasSelfCollision | ) |
| inline

Definition at line 529 of file btMultiBody.h.

## ◆ setJointPos()

void btMultiBody::setJointPos | ( | int | i,
|  | btScalar | q
| ) |  |

Definition at line 398 of file btMultiBody.cpp.

## ◆ setJointPosMultiDof() [1/2]

void btMultiBody::setJointPosMultiDof | ( | int | i,
|  | const double * | q
| ) |  |

Definition at line 405 of file btMultiBody.cpp.

## ◆ setJointPosMultiDof() [2/2]

void btMultiBody::setJointPosMultiDof | ( | int | i,
|  | const float * | q
| ) |  |

Definition at line 413 of file btMultiBody.cpp.

## ◆ setJointVel()

void btMultiBody::setJointVel | ( | int | i,
|  | btScalar | qdot
| ) |  |

Definition at line 423 of file btMultiBody.cpp.

## ◆ setJointVelMultiDof() [1/2]

void btMultiBody::setJointVelMultiDof | ( | int | i,
|  | const double * | qdot
| ) |  |

Definition at line 428 of file btMultiBody.cpp.

## ◆ setJointVelMultiDof() [2/2]

void btMultiBody::setJointVelMultiDof | ( | int | i,
|  | const float * | qdot
| ) |  |

Definition at line 434 of file btMultiBody.cpp.

## ◆ setLinearDamping()

void btMultiBody::setLinearDamping | ( | btScalar | damp | ) |
| inline

Definition at line 491 of file btMultiBody.h.

## ◆ setMaxAppliedImpulse()

void btMultiBody::setMaxAppliedImpulse | ( | btScalar | maxImp | ) |
| inline

Definition at line 525 of file btMultiBody.h.

## ◆ setMaxCoordinateVelocity()

void btMultiBody::setMaxCoordinateVelocity | ( | btScalar | maxVel | ) |
| inline

Definition at line 516 of file btMultiBody.h.

## ◆ setNumLinks()

void btMultiBody::setNumLinks | ( | int | numLinks | ) |
| inline

Definition at line 482 of file btMultiBody.h.

## ◆ setPosUpdated()

void btMultiBody::setPosUpdated | ( | bool | updated | ) |
| inline

Definition at line 549 of file btMultiBody.h.

## ◆ setupFixed()

void btMultiBody::setupFixed | ( | int | linkIndex,
|  | btScalar | mass,
|  | const btVector3 & | inertia,
|  | int | parent,
|  | const btQuaternion & | rotParentToThis,
|  | const btVector3 & | parentComToThisPivotOffset,
|  | const btVector3 & | thisPivotToThisComOffset,
|  | bool | deprecatedDisableParentCollision = `true`
| ) |  |

Definition at line 147 of file btMultiBody.cpp.

## ◆ setupPlanar()

void btMultiBody::setupPlanar | ( | int | i,
|  | btScalar | mass,
|  | const btVector3 & | inertia,
|  | int | parent,
|  | const btQuaternion & | rotParentToThis,
|  | const btVector3 & | rotationAxis,
|  | const btVector3 & | parentComToThisComOffset,
|  | bool | disableParentCollision = `false`
| ) |  |

Definition at line 289 of file btMultiBody.cpp.

## ◆ setupPrismatic()

void btMultiBody::setupPrismatic | ( | int | i,
|  | btScalar | mass,
|  | const btVector3 & | inertia,
|  | int | parent,
|  | const btQuaternion & | rotParentToThis,
|  | const btVector3 & | jointAxis,
|  | const btVector3 & | parentComToThisPivotOffset,
|  | const btVector3 & | thisPivotToThisComOffset,
|  | bool | disableParentCollision
| ) |  |

Definition at line 175 of file btMultiBody.cpp.

## ◆ setupRevolute()

void btMultiBody::setupRevolute | ( | int | linkIndex,
|  | btScalar | mass,
|  | const btVector3 & | inertia,
|  | int | parentIndex,
|  | const btQuaternion & | rotParentToThis,
|  | const btVector3 & | jointAxis,
|  | const btVector3 & | parentComToThisPivotOffset,
|  | const btVector3 & | thisPivotToThisComOffset,
|  | bool | disableParentCollision = `false`
| ) |  |

Definition at line 213 of file btMultiBody.cpp.

## ◆ setupSpherical()

void btMultiBody::setupSpherical | ( | int | linkIndex,
|  | btScalar | mass,
|  | const btVector3 & | inertia,
|  | int | parent,
|  | const btQuaternion & | rotParentToThis,
|  | const btVector3 & | parentComToThisPivotOffset,
|  | const btVector3 & | thisPivotToThisComOffset,
|  | bool | disableParentCollision = `false`
| ) |  |

Definition at line 249 of file btMultiBody.cpp.

## ◆ setUseGyroTerm()

void btMultiBody::setUseGyroTerm | ( | bool | useGyro | ) |
| inline

Definition at line 508 of file btMultiBody.h.

## ◆ setUserIndex()

void btMultiBody::setUserIndex | ( | int | index | ) |
| inline

users can point to their objects, userPointer is not used by Bullet

Definition at line 602 of file btMultiBody.h.

## ◆ setUserIndex2()

void btMultiBody::setUserIndex2 | ( | int | index | ) |
| inline

Definition at line 607 of file btMultiBody.h.

## ◆ setUserPointer()

void btMultiBody::setUserPointer | ( | void * | userPointer | ) |
| inline

users can point to their objects, userPointer is not used by Bullet

Definition at line 596 of file btMultiBody.h.

## ◆ setWorldToBaseRot()

void btMultiBody::setWorldToBaseRot | ( | const btQuaternion & | rot | ) |
| inline

Definition at line 221 of file btMultiBody.h.

## ◆ solveImatrix() [1/2]

void btMultiBody::solveImatrix | ( | const btVector3 & | rhs_top,
|  | const btVector3 & | rhs_bot,
|  | btScalar | result[6]
| ) |  | const
| private

solve I * x = rhs, so the result = invI * rhs

Special routine for calculating the inverse of a spatial inertia matrix the 6x6 matrix is stored as 4 blocks of 3x3 matrices

Definition at line 1273 of file btMultiBody.cpp.

## ◆ solveImatrix() [2/2]

void btMultiBody::solveImatrix | ( | const btSpatialForceVector & | rhs,
|  | btSpatialMotionVector & | result
| ) |  | const
| private

solve I * x = rhs, so the result = invI * rhs

Special routine for calculating the inverse of a spatial inertia matrix the 6x6 matrix is stored as 4 blocks of 3x3 matrices

Definition at line 1348 of file btMultiBody.cpp.

## ◆ spatialTransform()

void btMultiBody::spatialTransform | ( | const btMatrix3x3 & | rotation_matrix,
|  | const btVector3 & | displacement,
|  | const btVector3 & | top_in,
|  | const btVector3 & | bottom_in,
|  | btVector3 & | top_out,
|  | btVector3 & | bottom_out
| ) |  |
| static

Definition at line 40 of file btMultiBody.cpp.

## ◆ stepPositionsMultiDof()

void btMultiBody::stepPositionsMultiDof | ( | btScalar | dt,
|  | btScalar * | pq = `0`,
|  | btScalar * | pqd = `0`
| ) |  |

baseBody => quat is alibi and omega is local coor

Definition at line 1583 of file btMultiBody.cpp.

## ◆ updateCollisionObjectWorldTransforms()

void btMultiBody::updateCollisionObjectWorldTransforms | ( | btAlignedObjectArray< btQuaternion > & | scratch_q,
|  | btAlignedObjectArray< btVector3 > & | scratch_m
| ) |  |

Definition at line 1951 of file btMultiBody.cpp.

## ◆ updateLinksDofOffsets()

void btMultiBody::updateLinksDofOffsets | ( |  | ) |
| inlineprivate

Definition at line 628 of file btMultiBody.h.

## ◆ useGlobalVelocities()

void btMultiBody::useGlobalVelocities | ( | bool | use | ) |
| inline

Definition at line 542 of file btMultiBody.h.

## ◆ useRK4Integration()

void btMultiBody::useRK4Integration | ( | bool | use | ) |
| inline

Definition at line 540 of file btMultiBody.h.

## ◆ wakeUp()

void btMultiBody::wakeUp | ( |  | ) |

Definition at line 1864 of file btMultiBody.cpp.

## ◆ worldDirToLocal()

btVector3 btMultiBody::worldDirToLocal | ( | int | i,
|  | const btVector3 & | vec
| ) |  | const

Definition at line 515 of file btMultiBody.cpp.

## ◆ worldPosToLocal()

btVector3 btMultiBody::worldPosToLocal | ( | int | i,
|  | const btVector3 & | vec
| ) |  | const

Definition at line 475 of file btMultiBody.cpp.

## Member Data Documentation

## ◆ __posUpdated

bool btMultiBody::__posUpdated
| private

Definition at line 705 of file btMultiBody.h.

## ◆ m_angularDamping

btScalar btMultiBody::m_angularDamping
| private

Definition at line 699 of file btMultiBody.h.

## ◆ m_awake

bool btMultiBody::m_awake
| private

Definition at line 689 of file btMultiBody.h.

## ◆ m_baseCollider

btMultiBodyLinkCollider* btMultiBody::m_baseCollider
| private

Definition at line 643 of file btMultiBody.h.

## ◆ m_baseConstraintForce

btVector3 btMultiBody::m_baseConstraintForce
| private

Definition at line 655 of file btMultiBody.h.

## ◆ m_baseConstraintTorque

btVector3 btMultiBody::m_baseConstraintTorque
| private

Definition at line 656 of file btMultiBody.h.

## ◆ m_baseForce

btVector3 btMultiBody::m_baseForce
| private

Definition at line 652 of file btMultiBody.h.

## ◆ m_baseInertia

btVector3 btMultiBody::m_baseInertia
| private

Definition at line 650 of file btMultiBody.h.

## ◆ m_baseMass

btScalar btMultiBody::m_baseMass
| private

Definition at line 649 of file btMultiBody.h.

## ◆ m_baseName

const char* btMultiBody::m_baseName
| private

Definition at line 644 of file btMultiBody.h.

## ◆ m_basePos

btVector3 btMultiBody::m_basePos
| private

Definition at line 646 of file btMultiBody.h.

## ◆ m_baseQuat

btQuaternion btMultiBody::m_baseQuat
| private

Definition at line 647 of file btMultiBody.h.

## ◆ m_baseTorque

btVector3 btMultiBody::m_baseTorque
| private

Definition at line 653 of file btMultiBody.h.

## ◆ m_cachedInertiaLowerLeft

btMatrix3x3 btMultiBody::m_cachedInertiaLowerLeft
| private

Definition at line 682 of file btMultiBody.h.

## ◆ m_cachedInertiaLowerRight

btMatrix3x3 btMultiBody::m_cachedInertiaLowerRight
| private

Definition at line 683 of file btMultiBody.h.

## ◆ m_cachedInertiaTopLeft

btMatrix3x3 btMultiBody::m_cachedInertiaTopLeft
| private

Definition at line 680 of file btMultiBody.h.

## ◆ m_cachedInertiaTopRight

btMatrix3x3 btMultiBody::m_cachedInertiaTopRight
| private

Definition at line 681 of file btMultiBody.h.

## ◆ m_cachedInertiaValid

bool btMultiBody::m_cachedInertiaValid
| private

Definition at line 684 of file btMultiBody.h.

## ◆ m_canSleep

bool btMultiBody::m_canSleep
| private

Definition at line 690 of file btMultiBody.h.

## ◆ m_companionId

int btMultiBody::m_companionId
| private

Definition at line 697 of file btMultiBody.h.

## ◆ m_deltaV

btAlignedObjectArray<btScalar> btMultiBody::m_deltaV
| private

Definition at line 675 of file btMultiBody.h.

## ◆ m_dofCount

int btMultiBody::m_dofCount
| private

Definition at line 706 of file btMultiBody.h.

## ◆ m_fixedBase

bool btMultiBody::m_fixedBase
| private

Definition at line 686 of file btMultiBody.h.

## ◆ m_hasSelfCollision

bool btMultiBody::m_hasSelfCollision
| private

Definition at line 703 of file btMultiBody.h.

## ◆ m_internalNeedsJointFeedback

bool btMultiBody::m_internalNeedsJointFeedback
| private

the m_needsJointFeedback gets updated/computed during the stepVelocitiesMultiDof and it for internal usage only

Definition at line 713 of file btMultiBody.h.

## ◆ m_linearDamping

btScalar btMultiBody::m_linearDamping
| private

Definition at line 698 of file btMultiBody.h.

## ◆ m_links

btAlignedObjectArray<btMultibodyLink> btMultiBody::m_links
| private

Definition at line 658 of file btMultiBody.h.

## ◆ m_matrixBuf

btAlignedObjectArray<btMatrix3x3> btMultiBody::m_matrixBuf
| private

Definition at line 678 of file btMultiBody.h.

## ◆ m_maxAppliedImpulse

btScalar btMultiBody::m_maxAppliedImpulse
| private

Definition at line 701 of file btMultiBody.h.

## ◆ m_maxCoordinateVelocity

btScalar btMultiBody::m_maxCoordinateVelocity
| private

Definition at line 702 of file btMultiBody.h.

## ◆ m_posVarCnt

int btMultiBody::m_posVarCnt
| private

Definition at line 706 of file btMultiBody.h.

## ◆ m_realBuf

btAlignedObjectArray<btScalar> btMultiBody::m_realBuf
| private

Definition at line 676 of file btMultiBody.h.

## ◆ m_sleepTimer

btScalar btMultiBody::m_sleepTimer
| private

Definition at line 691 of file btMultiBody.h.

## ◆ m_useGlobalVelocities

bool btMultiBody::m_useGlobalVelocities
| private

Definition at line 708 of file btMultiBody.h.

## ◆ m_useGyroTerm

bool btMultiBody::m_useGyroTerm
| private

Definition at line 700 of file btMultiBody.h.

## ◆ m_userIndex

int btMultiBody::m_userIndex
| private

Definition at line 695 of file btMultiBody.h.

## ◆ m_userIndex2

int btMultiBody::m_userIndex2
| private

Definition at line 694 of file btMultiBody.h.

## ◆ m_useRK4

bool btMultiBody::m_useRK4
| private

Definition at line 708 of file btMultiBody.h.

## ◆ m_userObjectPointer

void* btMultiBody::m_userObjectPointer
| private

Definition at line 693 of file btMultiBody.h.

## ◆ m_vectorBuf

btAlignedObjectArray<btVector3> btMultiBody::m_vectorBuf
| private

Definition at line 677 of file btMultiBody.h.

The documentation for this class was generated from the following files:

- btMultiBody.h
- btMultiBody.cpp