Bullet Collision Detection & Physics Library: btPoint2PointConstraint Class Reference

Bullet Collision Detection & Physics Library

- Main Page
- Namespaces
- Classes
- Files

- Class List
- Class Hierarchy
- Class Members

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

point to point constraint between two rigidbodies each with a pivotpoint that descibes the 'ballsocket' location in local space More...

`#include <btPoint2PointConstraint.h>`

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

## Public Member Functions
| BT_DECLARE_ALIGNED_ALLOCATOR ()
| btPoint2PointConstraint (btRigidBody &rbA, btRigidBody &rbB, const btVector3 &pivotInA, const btVector3 &pivotInB)
| btPoint2PointConstraint (btRigidBody &rbA, const btVector3 &pivotInA)
virtual void | buildJacobian ()
| internal method used by the constraint solver, don't use them directly
virtual void | getInfo1 (btConstraintInfo1 *info)
| internal method used by the constraint solver, don't use them directly
void | getInfo1NonVirtual (btConstraintInfo1 *info)
virtual void | getInfo2 (btConstraintInfo2 *info)
| internal method used by the constraint solver, don't use them directly
void | getInfo2NonVirtual (btConstraintInfo2 *info, const btTransform &body0_trans, const btTransform &body1_trans)
void | updateRHS (btScalar timeStep)
void | setPivotA (const btVector3 &pivotA)
void | setPivotB (const btVector3 &pivotB)
const btVector3 & | getPivotInA () const
const btVector3 & | getPivotInB () const
virtual void | setParam (int num, btScalar value, int axis=-1)
| override the default global value of a parameter (such as ERP or CFM), optionally provide the axis (0..5).
virtual btScalar | getParam (int num, int axis=-1) const
| return the local value of parameter
virtual int | getFlags () const
virtual int | calculateSerializeBufferSize () const
virtual const char * | serialize (void *dataBuffer, btSerializer *serializer) const
| fills the dataBuffer and returns the struct name (and 0 on failure)
Public Member Functions inherited from btTypedConstraint
| BT_DECLARE_ALIGNED_ALLOCATOR ()
virtual | ~btTypedConstraint ()
| btTypedConstraint (btTypedConstraintType type, btRigidBody &rbA)
| btTypedConstraint (btTypedConstraintType type, btRigidBody &rbA, btRigidBody &rbB)
int | getOverrideNumSolverIterations () const
void | setOverrideNumSolverIterations (int overideNumIterations)
| override the number of constraint solver iterations used to solve this constraint -1 will use the default number of iterations, as specified in SolverInfo.m_numIterations
virtual void | buildJacobian ()
| internal method used by the constraint solver, don't use them directly
virtual void | setupSolverConstraint (btConstraintArray &ca, int solverBodyA, int solverBodyB, btScalar timeStep)
| internal method used by the constraint solver, don't use them directly
virtual void | getInfo1 (btConstraintInfo1 *info)=0
| internal method used by the constraint solver, don't use them directly
virtual void | getInfo2 (btConstraintInfo2 *info)=0
| internal method used by the constraint solver, don't use them directly
void | internalSetAppliedImpulse (btScalar appliedImpulse)
| internal method used by the constraint solver, don't use them directly
btScalar | internalGetAppliedImpulse ()
| internal method used by the constraint solver, don't use them directly
btScalar | getBreakingImpulseThreshold () const
void | setBreakingImpulseThreshold (btScalar threshold)
bool | isEnabled () const
void | setEnabled (bool enabled)
virtual void | solveConstraintObsolete (btSolverBody &, btSolverBody &, btScalar)
| internal method used by the constraint solver, don't use them directly
const btRigidBody & | getRigidBodyA () const
const btRigidBody & | getRigidBodyB () const
btRigidBody & | getRigidBodyA ()
btRigidBody & | getRigidBodyB ()
int | getUserConstraintType () const
void | setUserConstraintType (int userConstraintType)
void | setUserConstraintId (int uid)
int | getUserConstraintId () const
void | setUserConstraintPtr (void *ptr)
void * | getUserConstraintPtr ()
void | setJointFeedback (btJointFeedback *jointFeedback)
const btJointFeedback * | getJointFeedback () const
btJointFeedback * | getJointFeedback ()
int | getUid () const
bool | needsFeedback () const
void | enableFeedback (bool needsFeedback)
| enableFeedback will allow to read the applied linear and angular impulse use getAppliedImpulse, getAppliedLinearImpulse and getAppliedAngularImpulse to read feedback information
btScalar | getAppliedImpulse () const
| getAppliedImpulse is an estimated total applied impulse.
btTypedConstraintType | getConstraintType () const
void | setDbgDrawSize (btScalar dbgDrawSize)
btScalar | getDbgDrawSize ()
virtual void | setParam (int num, btScalar value, int axis=-1)=0
| override the default global value of a parameter (such as ERP or CFM), optionally provide the axis (0..5).
virtual btScalar | getParam (int num, int axis=-1) const =0
| return the local value of parameter
virtual int | calculateSerializeBufferSize () const
virtual const char * | serialize (void *dataBuffer, btSerializer *serializer) const
| fills the dataBuffer and returns the struct name (and 0 on failure)
Public Member Functions inherited from btTypedObject
| btTypedObject (int objectType)
int | getObjectType () const

## Public Attributes
bool | m_useSolveConstraintObsolete
| for backwards compatibility during the transition to 'getInfo/getInfo2'
btConstraintSetting | m_setting
Public Attributes inherited from btTypedObject
int | m_objectType

## Private Attributes
btJacobianEntry | m_jac [3]
btVector3 | m_pivotInA
btVector3 | m_pivotInB
int | m_flags
btScalar | m_erp
btScalar | m_cfm

## Additional Inherited Members
Static Public Member Functions inherited from btTypedConstraint
static btRigidBody & | getFixedBody ()
Protected Member Functions inherited from btTypedConstraint
btScalar | getMotorFactor (btScalar pos, btScalar lowLim, btScalar uppLim, btScalar vel, btScalar timeFact)
| internal method used by the constraint solver, don't use them directly
Protected Attributes inherited from btTypedConstraint
btRigidBody & | m_rbA
btRigidBody & | m_rbB
btScalar | m_appliedImpulse
btScalar | m_dbgDrawSize
btJointFeedback * | m_jointFeedback

## Detailed Description

point to point constraint between two rigidbodies each with a pivotpoint that descibes the 'ballsocket' location in local space

Definition at line 52 of file btPoint2PointConstraint.h.

## Constructor & Destructor Documentation

## ◆ btPoint2PointConstraint() [1/2]

btPoint2PointConstraint::btPoint2PointConstraint | ( | btRigidBody & | rbA,
|  | btRigidBody & | rbB,
|  | const btVector3 & | pivotInA,
|  | const btVector3 & | pivotInB
| ) |  |

Definition at line 20 of file btPoint2PointConstraint.cpp.

## ◆ btPoint2PointConstraint() [2/2]

btPoint2PointConstraint::btPoint2PointConstraint | ( | btRigidBody & | rbA,
|  | const btVector3 & | pivotInA
| ) |  |

Definition at line 25 of file btPoint2PointConstraint.cpp.

## Member Function Documentation

## ◆ BT_DECLARE_ALIGNED_ALLOCATOR()

btPoint2PointConstraint::BT_DECLARE_ALIGNED_ALLOCATOR | ( |  | ) |

## ◆ buildJacobian()

void btPoint2PointConstraint::buildJacobian | ( |  | ) |
| virtual

internal method used by the constraint solver, don't use them directly

we need it for both methods

Reimplemented from btTypedConstraint.

Definition at line 30 of file btPoint2PointConstraint.cpp.

## ◆ calculateSerializeBufferSize()

int btPoint2PointConstraint::calculateSerializeBufferSize | ( |  | ) | const
| inlinevirtual

Reimplemented from btTypedConstraint.

Definition at line 156 of file btPoint2PointConstraint.h.

## ◆ getFlags()

virtual int btPoint2PointConstraint::getFlags | ( |  | ) | const
| inlinevirtual

Definition at line 117 of file btPoint2PointConstraint.h.

## ◆ getInfo1()

void btPoint2PointConstraint::getInfo1 | ( | btConstraintInfo1 * | info | ) |
| virtual

internal method used by the constraint solver, don't use them directly

Implements btTypedConstraint.

Definition at line 56 of file btPoint2PointConstraint.cpp.

## ◆ getInfo1NonVirtual()

void btPoint2PointConstraint::getInfo1NonVirtual | ( | btConstraintInfo1 * | info | ) |

Definition at line 61 of file btPoint2PointConstraint.cpp.

## ◆ getInfo2()

void btPoint2PointConstraint::getInfo2 | ( | btConstraintInfo2 * | info | ) |
| virtual

internal method used by the constraint solver, don't use them directly

Implements btTypedConstraint.

Definition at line 75 of file btPoint2PointConstraint.cpp.

## ◆ getInfo2NonVirtual()

void btPoint2PointConstraint::getInfo2NonVirtual | ( | btConstraintInfo2 * | info,
|  | const btTransform & | body0_trans,
|  | const btTransform & | body1_trans
| ) |  |

Definition at line 80 of file btPoint2PointConstraint.cpp.

## ◆ getParam()

btScalar btPoint2PointConstraint::getParam | ( | int | num,
|  | int | axis = `-1`
| ) |  | const
| virtual

return the local value of parameter

Implements btTypedConstraint.

Definition at line 179 of file btPoint2PointConstraint.cpp.

## ◆ getPivotInA()

const btVector3 & btPoint2PointConstraint::getPivotInA | ( |  | ) | const
| inline

Definition at line 101 of file btPoint2PointConstraint.h.

## ◆ getPivotInB()

const btVector3 & btPoint2PointConstraint::getPivotInB | ( |  | ) | const
| inline

Definition at line 106 of file btPoint2PointConstraint.h.

## ◆ serialize()

const char * btPoint2PointConstraint::serialize | ( | void * | dataBuffer,
|  | btSerializer * | serializer
| ) |  | const
| inlinevirtual

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

Reimplemented from btTypedConstraint.

Definition at line 162 of file btPoint2PointConstraint.h.

## ◆ setParam()

void btPoint2PointConstraint::setParam | ( | int | num,
|  | btScalar | value,
|  | int | axis = `-1`
| ) |  |
| virtual

override the default global value of a parameter (such as ERP or CFM), optionally provide the axis (0..5).

If no axis is provided, it uses the default axis for this constraint.

Implements btTypedConstraint.

Definition at line 152 of file btPoint2PointConstraint.cpp.

## ◆ setPivotA()

void btPoint2PointConstraint::setPivotA | ( | const btVector3 & | pivotA | ) |
| inline

Definition at line 91 of file btPoint2PointConstraint.h.

## ◆ setPivotB()

void btPoint2PointConstraint::setPivotB | ( | const btVector3 & | pivotB | ) |
| inline

Definition at line 96 of file btPoint2PointConstraint.h.

## ◆ updateRHS()

void btPoint2PointConstraint::updateRHS | ( | btScalar | timeStep | ) |

Definition at line 145 of file btPoint2PointConstraint.cpp.

## Member Data Documentation

## ◆ m_cfm

btScalar btPoint2PointConstraint::m_cfm
| private

Definition at line 65 of file btPoint2PointConstraint.h.

## ◆ m_erp

btScalar btPoint2PointConstraint::m_erp
| private

Definition at line 64 of file btPoint2PointConstraint.h.

## ◆ m_flags

int btPoint2PointConstraint::m_flags
| private

Definition at line 63 of file btPoint2PointConstraint.h.

## ◆ m_jac

btJacobianEntry btPoint2PointConstraint::m_jac[3]
| private

Definition at line 58 of file btPoint2PointConstraint.h.

## ◆ m_pivotInA

btVector3 btPoint2PointConstraint::m_pivotInA
| private

Definition at line 60 of file btPoint2PointConstraint.h.

## ◆ m_pivotInB

btVector3 btPoint2PointConstraint::m_pivotInB
| private

Definition at line 61 of file btPoint2PointConstraint.h.

## ◆ m_setting

btConstraintSetting btPoint2PointConstraint::m_setting

Definition at line 73 of file btPoint2PointConstraint.h.

## ◆ m_useSolveConstraintObsolete

bool btPoint2PointConstraint::m_useSolveConstraintObsolete

for backwards compatibility during the transition to 'getInfo/getInfo2'

Definition at line 71 of file btPoint2PointConstraint.h.

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

- btPoint2PointConstraint.h
- btPoint2PointConstraint.cpp