Bullet Collision Detection & Physics Library: btMultiBodyMLCPConstraintSolver Class Reference

Bullet Collision Detection & Physics Library

Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
btMultiBodyMLCPConstraintSolver Class Reference

`#include <btMultiBodyMLCPConstraintSolver.h>`

Inheritance diagram for btMultiBodyMLCPConstraintSolver:
[legend]
Collaboration diagram for btMultiBodyMLCPConstraintSolver:
[legend]

## Public Member Functions
| btMultiBodyMLCPConstraintSolver (btMLCPSolverInterface *solver)
| Constructor. More...
virtual | ~btMultiBodyMLCPConstraintSolver ()
| Destructor. More...
void | setMLCPSolver (btMLCPSolverInterface *solver)
| Sets MLCP solver. Assumed it's not null. More...
int | getNumFallbacks () const
| Returns the number of fallbacks of using btSequentialImpulseConstraintSolver, which happens when the MLCP solver fails. More...
void | setNumFallbacks (int num)
| Sets the number of fallbacks. This function may be used to reset the number to zero. More...
virtual btConstraintSolverType | getSolverType () const
| Returns the constraint solver type. More...
Public Member Functions inherited from btMultiBodyConstraintSolver
| BT_DECLARE_ALIGNED_ALLOCATOR ()
virtual btScalar | solveGroup (btCollisionObject **bodies, int numBodies, btPersistentManifold **manifold, int numManifolds, btTypedConstraint **constraints, int numConstraints, const btContactSolverInfo &info, btIDebugDraw *debugDrawer, btDispatcher *dispatcher)
| this method should not be called, it was just used during porting/integration of Featherstone btMultiBody, providing backwards compatibility but no support for btMultiBodyConstraint (only contact constraints) More...
virtual btScalar | solveGroupCacheFriendlyFinish (btCollisionObject **bodies, int numBodies, const btContactSolverInfo &infoGlobal)
virtual void | solveMultiBodyGroup (btCollisionObject **bodies, int numBodies, btPersistentManifold **manifold, int numManifolds, btTypedConstraint **constraints, int numConstraints, btMultiBodyConstraint **multiBodyConstraints, int numMultiBodyConstraints, const btContactSolverInfo &info, btIDebugDraw *debugDrawer, btDispatcher *dispatcher)
Public Member Functions inherited from btSequentialImpulseConstraintSolver
| BT_DECLARE_ALIGNED_ALLOCATOR ()
| btSequentialImpulseConstraintSolver ()
virtual | ~btSequentialImpulseConstraintSolver ()
virtual btScalar | solveGroup (btCollisionObject **bodies, int numBodies, btPersistentManifold **manifold, int numManifolds, btTypedConstraint **constraints, int numConstraints, const btContactSolverInfo &info, btIDebugDraw *debugDrawer, btDispatcher *dispatcher)
| btSequentialImpulseConstraintSolver Sequentially applies impulses More...
virtual void | reset ()
| clear internal cached data and reset random seed More...
unsigned long | btRand2 ()
int | btRandInt2 (int n)
void | setRandSeed (unsigned long seed)
unsigned long | getRandSeed () const
virtual btConstraintSolverType | getSolverType () const
btSingleConstraintRowSolver | getActiveConstraintRowSolverGeneric ()
void | setConstraintRowSolverGeneric (btSingleConstraintRowSolver rowSolver)
btSingleConstraintRowSolver | getActiveConstraintRowSolverLowerLimit ()
void | setConstraintRowSolverLowerLimit (btSingleConstraintRowSolver rowSolver)
btSingleConstraintRowSolver | getScalarConstraintRowSolverGeneric ()
| Various implementations of solving a single constraint row using a generic equality constraint, using scalar reference, SSE2 or SSE4. More...
btSingleConstraintRowSolver | getSSE2ConstraintRowSolverGeneric ()
btSingleConstraintRowSolver | getSSE4_1ConstraintRowSolverGeneric ()
btSingleConstraintRowSolver | getScalarConstraintRowSolverLowerLimit ()
| Various implementations of solving a single constraint row using an inequality (lower limit) constraint, using scalar reference, SSE2 or SSE4. More...
btSingleConstraintRowSolver | getSSE2ConstraintRowSolverLowerLimit ()
btSingleConstraintRowSolver | getSSE4_1ConstraintRowSolverLowerLimit ()
Public Member Functions inherited from btConstraintSolver
virtual | ~btConstraintSolver ()
virtual void | prepareSolve (int, int)
virtual btScalar | solveGroup (btCollisionObject **bodies, int numBodies, btPersistentManifold **manifold, int numManifolds, btTypedConstraint **constraints, int numConstraints, const btContactSolverInfo &info, class btIDebugDraw *debugDrawer, btDispatcher *dispatcher)=0
| solve a group of constraints More...
virtual void | allSolved (const btContactSolverInfo &, class btIDebugDraw *)
virtual void | reset ()=0
| clear internal cached data and reset random seed More...
virtual btConstraintSolverType | getSolverType () const =0

## Protected Member Functions
virtual void | createMLCPFast (const btContactSolverInfo &infoGlobal)
| Constructs MLCP terms, which are `m_A`, `m_b`, `m_lo`, and `m_hi`. More...
void | createMLCPFastRigidBody (const btContactSolverInfo &infoGlobal)
| Constructs MLCP terms for constraints of two rigid bodies. More...
void | createMLCPFastMultiBody (const btContactSolverInfo &infoGlobal)
| Constructs MLCP terms for constraints of two multi-bodies or one rigid body and one multibody. More...
virtual bool | solveMLCP (const btContactSolverInfo &infoGlobal)
| Solves MLCP and returns the success. More...
btScalar | solveGroupCacheFriendlySetup (btCollisionObject **bodies, int numBodies, btPersistentManifold **manifoldPtr, int numManifolds, btTypedConstraint **constraints, int numConstraints, const btContactSolverInfo &infoGlobal, btIDebugDraw *debugDrawer) BT_OVERRIDE
btScalar | solveGroupCacheFriendlyIterations (btCollisionObject **bodies, int numBodies, btPersistentManifold **manifoldPtr, int numManifolds, btTypedConstraint **constraints, int numConstraints, const btContactSolverInfo &infoGlobal, btIDebugDraw *debugDrawer)
Protected Member Functions inherited from btMultiBodyConstraintSolver
btScalar | resolveSingleConstraintRowGeneric (const btMultiBodySolverConstraint &c)
btScalar | resolveConeFrictionConstraintRows (const btMultiBodySolverConstraint &cA1, const btMultiBodySolverConstraint &cB)
void | convertContacts (btPersistentManifold **manifoldPtr, int numManifolds, const btContactSolverInfo &infoGlobal)
btMultiBodySolverConstraint & | addMultiBodyFrictionConstraint (const btVector3 &normalAxis, const btScalar &appliedImpulse, btPersistentManifold *manifold, int frictionIndex, btManifoldPoint &cp, btCollisionObject *colObj0, btCollisionObject *colObj1, btScalar relaxation, const btContactSolverInfo &infoGlobal, btScalar desiredVelocity=0, btScalar cfmSlip=0)
btMultiBodySolverConstraint & | addMultiBodyTorsionalFrictionConstraint (const btVector3 &normalAxis, btPersistentManifold *manifold, int frictionIndex, btManifoldPoint &cp, btScalar combinedTorsionalFriction, btCollisionObject *colObj0, btCollisionObject *colObj1, btScalar relaxation, const btContactSolverInfo &infoGlobal, btScalar desiredVelocity=0, btScalar cfmSlip=0)
btMultiBodySolverConstraint & | addMultiBodySpinningFrictionConstraint (const btVector3 &normalAxis, btPersistentManifold *manifold, int frictionIndex, btManifoldPoint &cp, btScalar combinedTorsionalFriction, btCollisionObject *colObj0, btCollisionObject *colObj1, btScalar relaxation, const btContactSolverInfo &infoGlobal, btScalar desiredVelocity=0, btScalar cfmSlip=0)
void | setupMultiBodyJointLimitConstraint (btMultiBodySolverConstraint &constraintRow, btScalar *jacA, btScalar *jacB, btScalar penetration, btScalar combinedFrictionCoeff, btScalar combinedRestitutionCoeff, const btContactSolverInfo &infoGlobal)
void | setupMultiBodyContactConstraint (btMultiBodySolverConstraint &solverConstraint, const btVector3 &contactNormal, const btScalar &appliedImpulse, btManifoldPoint &cp, const btContactSolverInfo &infoGlobal, btScalar &relaxation, bool isFriction, btScalar desiredVelocity=0, btScalar cfmSlip=0)
void | setupMultiBodyTorsionalFrictionConstraint (btMultiBodySolverConstraint &solverConstraint, const btVector3 &contactNormal, btManifoldPoint &cp, btScalar combinedTorsionalFriction, const btContactSolverInfo &infoGlobal, btScalar &relaxation, bool isFriction, btScalar desiredVelocity=0, btScalar cfmSlip=0)
void | convertMultiBodyContact (btPersistentManifold *manifold, const btContactSolverInfo &infoGlobal)
virtual btScalar | solveGroupCacheFriendlySetup (btCollisionObject **bodies, int numBodies, btPersistentManifold **manifoldPtr, int numManifolds, btTypedConstraint **constraints, int numConstraints, const btContactSolverInfo &infoGlobal, btIDebugDraw *debugDrawer)
virtual btScalar | solveSingleIteration (int iteration, btCollisionObject **bodies, int numBodies, btPersistentManifold **manifoldPtr, int numManifolds, btTypedConstraint **constraints, int numConstraints, const btContactSolverInfo &infoGlobal, btIDebugDraw *debugDrawer)
void | applyDeltaVee (btScalar *deltaV, btScalar impulse, int velocityIndex, int ndof)
void | writeBackSolverBodyToMultiBody (btMultiBodySolverConstraint &constraint, btScalar deltaTime)
Protected Member Functions inherited from btSequentialImpulseConstraintSolver
void | setupSolverFunctions (bool useSimd)
void | setupFrictionConstraint (btSolverConstraint &solverConstraint, const btVector3 &normalAxis, int solverBodyIdA, int solverBodyIdB, btManifoldPoint &cp, const btVector3 &rel_pos1, const btVector3 &rel_pos2, btCollisionObject *colObj0, btCollisionObject *colObj1, btScalar relaxation, const btContactSolverInfo &infoGlobal, btScalar desiredVelocity=0., btScalar cfmSlip=0.)
void | setupTorsionalFrictionConstraint (btSolverConstraint &solverConstraint, const btVector3 &normalAxis, int solverBodyIdA, int solverBodyIdB, btManifoldPoint &cp, btScalar combinedTorsionalFriction, const btVector3 &rel_pos1, const btVector3 &rel_pos2, btCollisionObject *colObj0, btCollisionObject *colObj1, btScalar relaxation, btScalar desiredVelocity=0., btScalar cfmSlip=0.)
btSolverConstraint & | addFrictionConstraint (const btVector3 &normalAxis, int solverBodyIdA, int solverBodyIdB, int frictionIndex, btManifoldPoint &cp, const btVector3 &rel_pos1, const btVector3 &rel_pos2, btCollisionObject *colObj0, btCollisionObject *colObj1, btScalar relaxation, const btContactSolverInfo &infoGlobal, btScalar desiredVelocity=0., btScalar cfmSlip=0.)
btSolverConstraint & | addTorsionalFrictionConstraint (const btVector3 &normalAxis, int solverBodyIdA, int solverBodyIdB, int frictionIndex, btManifoldPoint &cp, btScalar torsionalFriction, const btVector3 &rel_pos1, const btVector3 &rel_pos2, btCollisionObject *colObj0, btCollisionObject *colObj1, btScalar relaxation, btScalar desiredVelocity=0, btScalar cfmSlip=0.f)
void | setupContactConstraint (btSolverConstraint &solverConstraint, int solverBodyIdA, int solverBodyIdB, btManifoldPoint &cp, const btContactSolverInfo &infoGlobal, btScalar &relaxation, const btVector3 &rel_pos1, const btVector3 &rel_pos2)
void | setFrictionConstraintImpulse (btSolverConstraint &solverConstraint, int solverBodyIdA, int solverBodyIdB, btManifoldPoint &cp, const btContactSolverInfo &infoGlobal)
btScalar | restitutionCurve (btScalar rel_vel, btScalar restitution, btScalar velocityThreshold)
virtual void | convertContacts (btPersistentManifold **manifoldPtr, int numManifolds, const btContactSolverInfo &infoGlobal)
void | convertContact (btPersistentManifold *manifold, const btContactSolverInfo &infoGlobal)
virtual void | convertJoints (btTypedConstraint **constraints, int numConstraints, const btContactSolverInfo &infoGlobal)
void | convertJoint (btSolverConstraint *currentConstraintRow, btTypedConstraint *constraint, const btTypedConstraint::btConstraintInfo1 &info1, int solverBodyIdA, int solverBodyIdB, const btContactSolverInfo &infoGlobal)
virtual void | convertBodies (btCollisionObject **bodies, int numBodies, const btContactSolverInfo &infoGlobal)
btScalar | resolveSplitPenetrationSIMD (btSolverBody &bodyA, btSolverBody &bodyB, const btSolverConstraint &contactConstraint)
btScalar | resolveSplitPenetrationImpulseCacheFriendly (btSolverBody &bodyA, btSolverBody &bodyB, const btSolverConstraint &contactConstraint)
int | getOrInitSolverBody (btCollisionObject &body, btScalar timeStep)
void | initSolverBody (btSolverBody *solverBody, btCollisionObject *collisionObject, btScalar timeStep)
btScalar | resolveSingleConstraintRowGeneric (btSolverBody &bodyA, btSolverBody &bodyB, const btSolverConstraint &contactConstraint)
btScalar | resolveSingleConstraintRowGenericSIMD (btSolverBody &bodyA, btSolverBody &bodyB, const btSolverConstraint &contactConstraint)
btScalar | resolveSingleConstraintRowLowerLimit (btSolverBody &bodyA, btSolverBody &bodyB, const btSolverConstraint &contactConstraint)
btScalar | resolveSingleConstraintRowLowerLimitSIMD (btSolverBody &bodyA, btSolverBody &bodyB, const btSolverConstraint &contactConstraint)
btScalar | resolveSplitPenetrationImpulse (btSolverBody &bodyA, btSolverBody &bodyB, const btSolverConstraint &contactConstraint)
void | writeBackContacts (int iBegin, int iEnd, const btContactSolverInfo &infoGlobal)
void | writeBackJoints (int iBegin, int iEnd, const btContactSolverInfo &infoGlobal)
void | writeBackBodies (int iBegin, int iEnd, const btContactSolverInfo &infoGlobal)
virtual void | solveGroupCacheFriendlySplitImpulseIterations (btCollisionObject **bodies, int numBodies, btPersistentManifold **manifoldPtr, int numManifolds, btTypedConstraint **constraints, int numConstraints, const btContactSolverInfo &infoGlobal, btIDebugDraw *debugDrawer)
virtual btScalar | solveGroupCacheFriendlyFinish (btCollisionObject **bodies, int numBodies, const btContactSolverInfo &infoGlobal)
virtual btScalar | solveSingleIteration (int iteration, btCollisionObject **bodies, int numBodies, btPersistentManifold **manifoldPtr, int numManifolds, btTypedConstraint **constraints, int numConstraints, const btContactSolverInfo &infoGlobal, btIDebugDraw *debugDrawer)
virtual btScalar | solveGroupCacheFriendlySetup (btCollisionObject **bodies, int numBodies, btPersistentManifold **manifoldPtr, int numManifolds, btTypedConstraint **constraints, int numConstraints, const btContactSolverInfo &infoGlobal, btIDebugDraw *debugDrawer)
virtual btScalar | solveGroupCacheFriendlyIterations (btCollisionObject **bodies, int numBodies, btPersistentManifold **manifoldPtr, int numManifolds, btTypedConstraint **constraints, int numConstraints, const btContactSolverInfo &infoGlobal, btIDebugDraw *debugDrawer)

## Protected Attributes
btAlignedObjectArray< int > | m_limitDependencies
| Indices of normal contact constraint associated with frictional contact constraint for rigid bodies. More...
btAlignedObjectArray< int > | m_multiBodyLimitDependencies
| Indices of normal contact constraint associated with frictional contact constraint for multibodies. More...
btAlignedObjectArray< btSolverConstraint * > | m_allConstraintPtrArray
| Array of all the rigid body constraints. More...
btAlignedObjectArray< btMultiBodySolverConstraint * > | m_multiBodyAllConstraintPtrArray
| Array of all the multibody constraints. More...
btMLCPSolverInterface * | m_solver
| MLCP solver. More...
int | m_fallback
| Count of fallbacks of using btSequentialImpulseConstraintSolver, which happens when the MLCP solver fails. More...
MLCP Formulation for Rigid Bodies
btMatrixXu | m_A
| A matrix in the MLCP formulation. More...
btVectorXu | m_b
| b vector in the MLCP formulation. More...
btVectorXu | m_x
| Constraint impulse, which is an output of MLCP solving. More...
btVectorXu | m_lo
| Lower bound of constraint impulse, `m_x`. More...
btVectorXu | m_hi
| Upper bound of constraint impulse, `m_x`. More...
Cache Variables for Split Impulse for Rigid Bodies
When using 'split impulse' we solve two separate (M)LCPs
btVectorXu | m_bSplit
| Split impulse Cache vector corresponding to `m_b`. More...
btVectorXu | m_xSplit
| Split impulse cache vector corresponding to `m_x`. More...
MLCP Formulation for Multibodies
btMatrixXu | m_multiBodyA
| A matrix in the MLCP formulation. More...
btVectorXu | m_multiBodyB
| b vector in the MLCP formulation. More...
btVectorXu | m_multiBodyX
| Constraint impulse, which is an output of MLCP solving. More...
btVectorXu | m_multiBodyLo
| Lower bound of constraint impulse, `m_x`. More...
btVectorXu | m_multiBodyHi
| Upper bound of constraint impulse, `m_x`. More...
MLCP Scratch Variables
The following scratch variables are not stateful – contents are cleared prior to each use. They are only cached here to avoid extra memory allocations and deallocations and to ensure that multiple instances of the solver can be run in parallel.
btMatrixXu | m_scratchJ3
| Cache variable for constraint Jacobian matrix. More...
btMatrixXu | m_scratchJInvM3
| Cache variable for constraint Jacobian times inverse mass matrix. More...
btAlignedObjectArray< int > | m_scratchOfs
| Cache variable for offsets. More...
Protected Attributes inherited from btMultiBodyConstraintSolver
btMultiBodyConstraintArray | m_multiBodyNonContactConstraints
btMultiBodyConstraintArray | m_multiBodyNormalContactConstraints
btMultiBodyConstraintArray | m_multiBodyFrictionContactConstraints
btMultiBodyConstraintArray | m_multiBodyTorsionalFrictionContactConstraints
btMultiBodyConstraintArray | m_multiBodySpinningFrictionContactConstraints
btMultiBodyJacobianData | m_data
btMultiBodyConstraint ** | m_tmpMultiBodyConstraints
int | m_tmpNumMultiBodyConstraints
Protected Attributes inherited from btSequentialImpulseConstraintSolver
btAlignedObjectArray< btSolverBody > | m_tmpSolverBodyPool
btConstraintArray | m_tmpSolverContactConstraintPool
btConstraintArray | m_tmpSolverNonContactConstraintPool
btConstraintArray | m_tmpSolverContactFrictionConstraintPool
btConstraintArray | m_tmpSolverContactRollingFrictionConstraintPool
btAlignedObjectArray< int > | m_orderTmpConstraintPool
btAlignedObjectArray< int > | m_orderNonContactConstraintPool
btAlignedObjectArray< int > | m_orderFrictionConstraintPool
btAlignedObjectArray< btTypedConstraint::btConstraintInfo1 > | m_tmpConstraintSizesPool
int | m_maxOverrideNumSolverIterations
int | m_fixedBodyId
btAlignedObjectArray< int > | m_kinematicBodyUniqueIdToSolverBodyTable
btSingleConstraintRowSolver | m_resolveSingleConstraintRowGeneric
btSingleConstraintRowSolver | m_resolveSingleConstraintRowLowerLimit
btSingleConstraintRowSolver | m_resolveSplitPenetrationImpulse
int | m_cachedSolverMode
btScalar | m_leastSquaresResidual
unsigned long | m_btSeed2
| m_btSeed2 is used for re-arranging the constraint rows. improves convergence/quality of friction More...

## Additional Inherited Members
Public Attributes inherited from btSequentialImpulseConstraintSolver
btSolverAnalyticsData | m_analyticsData
Static Protected Member Functions inherited from btSequentialImpulseConstraintSolver
static void | applyAnisotropicFriction (btCollisionObject *colObj, btVector3 &frictionDirection, int frictionMode)

## Detailed Description

Definition at line 26 of file btMultiBodyMLCPConstraintSolver.h.

## Constructor & Destructor Documentation

## ◆ btMultiBodyMLCPConstraintSolver()

btMultiBodyMLCPConstraintSolver::btMultiBodyMLCPConstraintSolver | ( | btMLCPSolverInterface * | solver | ) |
| explicit

Constructor.

Parameters

  [in] | solver | MLCP solver. Assumed it's not null.
  [in] | maxLCPSize | Maximum size of LCP to solve using MLCP solver. If the MLCP size exceeds this number, sequaltial impulse method will be used.

Definition at line 937 of file btMultiBodyMLCPConstraintSolver.cpp.

## ◆ ~btMultiBodyMLCPConstraintSolver()

btMultiBodyMLCPConstraintSolver::~btMultiBodyMLCPConstraintSolver | ( |  | ) |
| virtual

Destructor.

Definition at line 943 of file btMultiBodyMLCPConstraintSolver.cpp.

## Member Function Documentation

## ◆ createMLCPFast()

void btMultiBodyMLCPConstraintSolver::createMLCPFast | ( | const btContactSolverInfo & | infoGlobal | ) |
| protectedvirtual

Constructs MLCP terms, which are `m_A`, `m_b`, `m_lo`, and `m_hi`.

Definition at line 236 of file btMultiBodyMLCPConstraintSolver.cpp.

## ◆ createMLCPFastMultiBody()

void btMultiBodyMLCPConstraintSolver::createMLCPFastMultiBody | ( | const btContactSolverInfo & | infoGlobal | ) |
| protected

Constructs MLCP terms for constraints of two multi-bodies or one rigid body and one multibody.

Definition at line 556 of file btMultiBodyMLCPConstraintSolver.cpp.

## ◆ createMLCPFastRigidBody()

void btMultiBodyMLCPConstraintSolver::createMLCPFastRigidBody | ( | const btContactSolverInfo & | infoGlobal | ) |
| protected

Constructs MLCP terms for constraints of two rigid bodies.

fill the upper triangle of the matrix, to make it symmetric

Definition at line 242 of file btMultiBodyMLCPConstraintSolver.cpp.

## ◆ getNumFallbacks()

int btMultiBodyMLCPConstraintSolver::getNumFallbacks | ( |  | ) | const

Returns the number of fallbacks of using btSequentialImpulseConstraintSolver, which happens when the MLCP solver fails.

Definition at line 953 of file btMultiBodyMLCPConstraintSolver.cpp.

## ◆ getSolverType()

btConstraintSolverType btMultiBodyMLCPConstraintSolver::getSolverType | ( |  | ) | const
| virtual

Returns the constraint solver type.

Reimplemented from btSequentialImpulseConstraintSolver.

Definition at line 963 of file btMultiBodyMLCPConstraintSolver.cpp.

## ◆ setMLCPSolver()

void btMultiBodyMLCPConstraintSolver::setMLCPSolver | ( | btMLCPSolverInterface * | solver | ) |

Sets MLCP solver. Assumed it's not null.

Definition at line 948 of file btMultiBodyMLCPConstraintSolver.cpp.

## ◆ setNumFallbacks()

void btMultiBodyMLCPConstraintSolver::setNumFallbacks | ( | int | num | ) |

Sets the number of fallbacks. This function may be used to reset the number to zero.

Definition at line 958 of file btMultiBodyMLCPConstraintSolver.cpp.

## ◆ solveGroupCacheFriendlyIterations()

btScalar btMultiBodyMLCPConstraintSolver::solveGroupCacheFriendlyIterations | ( | btCollisionObject ** | bodies,
|  | int | numBodies,
|  | btPersistentManifold ** | manifoldPtr,
|  | int | numManifolds,
|  | btTypedConstraint ** | constraints,
|  | int | numConstraints,
|  | const btContactSolverInfo & | infoGlobal,
|  | btIDebugDraw * | debugDrawer
| ) |  |
| protectedvirtual

Reimplemented from btSequentialImpulseConstraintSolver.

Definition at line 846 of file btMultiBodyMLCPConstraintSolver.cpp.

## ◆ solveGroupCacheFriendlySetup()

btScalar btMultiBodyMLCPConstraintSolver::solveGroupCacheFriendlySetup | ( | btCollisionObject ** | bodies,
|  | int | numBodies,
|  | btPersistentManifold ** | manifoldPtr,
|  | int | numManifolds,
|  | btTypedConstraint ** | constraints,
|  | int | numConstraints,
|  | const btContactSolverInfo & | infoGlobal,
|  | btIDebugDraw * | debugDrawer
| ) |  |
| protectedvirtual

Reimplemented from btMultiBodyConstraintSolver.

Definition at line 691 of file btMultiBodyMLCPConstraintSolver.cpp.

## ◆ solveMLCP()

bool btMultiBodyMLCPConstraintSolver::solveMLCP | ( | const btContactSolverInfo & | infoGlobal | ) |
| protectedvirtual

Solves MLCP and returns the success.

Definition at line 657 of file btMultiBodyMLCPConstraintSolver.cpp.

## Member Data Documentation

## ◆ m_A

btMatrixXu btMultiBodyMLCPConstraintSolver::m_A
| protected

A matrix in the MLCP formulation.

Definition at line 33 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_allConstraintPtrArray

btAlignedObjectArray<btSolverConstraint*> btMultiBodyMLCPConstraintSolver::m_allConstraintPtrArray
| protected

Array of all the rigid body constraints.

Definition at line 98 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_b

btVectorXu btMultiBodyMLCPConstraintSolver::m_b
| protected

b vector in the MLCP formulation.

Definition at line 36 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_bSplit

btVectorXu btMultiBodyMLCPConstraintSolver::m_bSplit
| protected

Split impulse Cache vector corresponding to `m_b`.

Definition at line 54 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_fallback

int btMultiBodyMLCPConstraintSolver::m_fallback
| protected

Count of fallbacks of using btSequentialImpulseConstraintSolver, which happens when the MLCP solver fails.

Definition at line 107 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_hi

btVectorXu btMultiBodyMLCPConstraintSolver::m_hi
| protected

Upper bound of constraint impulse, `m_x`.

Definition at line 45 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_limitDependencies

btAlignedObjectArray<int> btMultiBodyMLCPConstraintSolver::m_limitDependencies
| protected

Indices of normal contact constraint associated with frictional contact constraint for rigid bodies.

This is used by the MLCP solver to update the upper bounds of frictional contact impulse given intermediate normal contact impulse. For example, i-th element represents the index of a normal constraint that is accosiated with i-th frictional contact constraint if i-th constraint is a frictional contact constraint. Otherwise, -1.

Definition at line 87 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_lo

btVectorXu btMultiBodyMLCPConstraintSolver::m_lo
| protected

Lower bound of constraint impulse, `m_x`.

Definition at line 42 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_multiBodyA

btMatrixXu btMultiBodyMLCPConstraintSolver::m_multiBodyA
| protected

A matrix in the MLCP formulation.

Definition at line 65 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_multiBodyAllConstraintPtrArray

btAlignedObjectArray<btMultiBodySolverConstraint*> btMultiBodyMLCPConstraintSolver::m_multiBodyAllConstraintPtrArray
| protected

Array of all the multibody constraints.

Definition at line 101 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_multiBodyB

btVectorXu btMultiBodyMLCPConstraintSolver::m_multiBodyB
| protected

b vector in the MLCP formulation.

Definition at line 68 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_multiBodyHi

btVectorXu btMultiBodyMLCPConstraintSolver::m_multiBodyHi
| protected

Upper bound of constraint impulse, `m_x`.

Definition at line 77 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_multiBodyLimitDependencies

btAlignedObjectArray<int> btMultiBodyMLCPConstraintSolver::m_multiBodyLimitDependencies
| protected

Indices of normal contact constraint associated with frictional contact constraint for multibodies.

This is used by the MLCP solver to update the upper bounds of frictional contact impulse given intermediate normal contact impulse. For example, i-th element represents the index of a normal constraint that is accosiated with i-th frictional contact constraint if i-th constraint is a frictional contact constraint. Otherwise, -1.

Definition at line 95 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_multiBodyLo

btVectorXu btMultiBodyMLCPConstraintSolver::m_multiBodyLo
| protected

Lower bound of constraint impulse, `m_x`.

Definition at line 74 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_multiBodyX

btVectorXu btMultiBodyMLCPConstraintSolver::m_multiBodyX
| protected

Constraint impulse, which is an output of MLCP solving.

Definition at line 71 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_scratchJ3

btMatrixXu btMultiBodyMLCPConstraintSolver::m_scratchJ3
| protected

Cache variable for constraint Jacobian matrix.

Definition at line 117 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_scratchJInvM3

btMatrixXu btMultiBodyMLCPConstraintSolver::m_scratchJInvM3
| protected

Cache variable for constraint Jacobian times inverse mass matrix.

Definition at line 120 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_scratchOfs

btAlignedObjectArray<int> btMultiBodyMLCPConstraintSolver::m_scratchOfs
| protected

Cache variable for offsets.

Definition at line 123 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_solver

btMLCPSolverInterface* btMultiBodyMLCPConstraintSolver::m_solver
| protected

MLCP solver.

Definition at line 104 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_x

btVectorXu btMultiBodyMLCPConstraintSolver::m_x
| protected

Constraint impulse, which is an output of MLCP solving.

Definition at line 39 of file btMultiBodyMLCPConstraintSolver.h.

## ◆ m_xSplit

btVectorXu btMultiBodyMLCPConstraintSolver::m_xSplit
| protected

Split impulse cache vector corresponding to `m_x`.

Definition at line 57 of file btMultiBodyMLCPConstraintSolver.h.

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

- btMultiBodyMLCPConstraintSolver.h
- btMultiBodyMLCPConstraintSolver.cpp