#include <b2WeldJoint.h>
Public Member Functions | |
void | Dump () |
Dump to b2Log. | |
b2Vec2 | GetAnchorA () const |
Get the anchor point on bodyA in world coordinates. | |
b2Vec2 | GetAnchorB () const |
Get the anchor point on bodyB in world coordinates. | |
float32 | GetDampingRatio () const |
float32 | GetFrequency () const |
const b2Vec2 & | GetLocalAnchorA () const |
The local anchor point relative to bodyA's origin. | |
const b2Vec2 & | GetLocalAnchorB () const |
The local anchor point relative to bodyB's origin. | |
b2Vec2 | GetReactionForce (float32 inv_dt) const |
Get the reaction force on bodyB at the joint anchor in Newtons. | |
float32 | GetReactionTorque (float32 inv_dt) const |
Get the reaction torque on bodyB in N*m. | |
float32 | GetReferenceAngle () const |
Get the reference angle. | |
void | SetDampingRatio (float32 ratio) |
Set/get damping ratio. | |
void | SetFrequency (float32 hz) |
Set/get frequency in Hz. | |
Protected Member Functions | |
b2WeldJoint (const b2WeldJointDef *def) | |
void | InitVelocityConstraints (const b2SolverData &data) |
bool | SolvePositionConstraints (const b2SolverData &data) |
void | SolveVelocityConstraints (const b2SolverData &data) |
Protected Attributes | |
float32 | m_bias |
float32 | m_dampingRatio |
float32 | m_frequencyHz |
float32 | m_gamma |
b2Vec3 | m_impulse |
int32 | m_indexA |
int32 | m_indexB |
float32 | m_invIA |
float32 | m_invIB |
float32 | m_invMassA |
float32 | m_invMassB |
b2Vec2 | m_localAnchorA |
b2Vec2 | m_localAnchorB |
b2Vec2 | m_localCenterA |
b2Vec2 | m_localCenterB |
b2Mat33 | m_mass |
b2Vec2 | m_rA |
b2Vec2 | m_rB |
float32 | m_referenceAngle |
Friends | |
class | b2Joint |
A weld joint essentially glues two bodies together. A weld joint may distort somewhat because the island constraint solver is approximate.
Definition at line 62 of file b2WeldJoint.h.
b2WeldJoint::b2WeldJoint | ( | const b2WeldJointDef * | def | ) | [protected] |
Definition at line 46 of file b2WeldJoint.cpp.
void b2WeldJoint::Dump | ( | ) | [virtual] |
b2Vec2 b2WeldJoint::GetAnchorA | ( | ) | const [virtual] |
Get the anchor point on bodyA in world coordinates.
Implements b2Joint.
Definition at line 308 of file b2WeldJoint.cpp.
b2Vec2 b2WeldJoint::GetAnchorB | ( | ) | const [virtual] |
Get the anchor point on bodyB in world coordinates.
Implements b2Joint.
Definition at line 313 of file b2WeldJoint.cpp.
float32 b2WeldJoint::GetDampingRatio | ( | ) | const [inline] |
Definition at line 86 of file b2WeldJoint.h.
float32 b2WeldJoint::GetFrequency | ( | ) | const [inline] |
Definition at line 82 of file b2WeldJoint.h.
const b2Vec2& b2WeldJoint::GetLocalAnchorA | ( | ) | const [inline] |
The local anchor point relative to bodyA's origin.
Definition at line 72 of file b2WeldJoint.h.
const b2Vec2& b2WeldJoint::GetLocalAnchorB | ( | ) | const [inline] |
The local anchor point relative to bodyB's origin.
Definition at line 75 of file b2WeldJoint.h.
b2Vec2 b2WeldJoint::GetReactionForce | ( | float32 | inv_dt | ) | const [virtual] |
Get the reaction force on bodyB at the joint anchor in Newtons.
Implements b2Joint.
Definition at line 318 of file b2WeldJoint.cpp.
float32 b2WeldJoint::GetReactionTorque | ( | float32 | inv_dt | ) | const [virtual] |
Get the reaction torque on bodyB in N*m.
Implements b2Joint.
Definition at line 324 of file b2WeldJoint.cpp.
float32 b2WeldJoint::GetReferenceAngle | ( | ) | const [inline] |
Get the reference angle.
Definition at line 78 of file b2WeldJoint.h.
void b2WeldJoint::InitVelocityConstraints | ( | const b2SolverData & | data | ) | [protected, virtual] |
Implements b2Joint.
Definition at line 58 of file b2WeldJoint.cpp.
void b2WeldJoint::SetDampingRatio | ( | float32 | ratio | ) | [inline] |
Set/get damping ratio.
Definition at line 85 of file b2WeldJoint.h.
void b2WeldJoint::SetFrequency | ( | float32 | hz | ) | [inline] |
Set/get frequency in Hz.
Definition at line 81 of file b2WeldJoint.h.
bool b2WeldJoint::SolvePositionConstraints | ( | const b2SolverData & | data | ) | [protected, virtual] |
Implements b2Joint.
Definition at line 227 of file b2WeldJoint.cpp.
void b2WeldJoint::SolveVelocityConstraints | ( | const b2SolverData & | data | ) | [protected, virtual] |
Implements b2Joint.
Definition at line 169 of file b2WeldJoint.cpp.
friend class b2Joint [friend] |
Definition at line 93 of file b2WeldJoint.h.
float32 b2WeldJoint::m_bias [protected] |
Definition at line 103 of file b2WeldJoint.h.
float32 b2WeldJoint::m_dampingRatio [protected] |
Definition at line 102 of file b2WeldJoint.h.
float32 b2WeldJoint::m_frequencyHz [protected] |
Definition at line 101 of file b2WeldJoint.h.
float32 b2WeldJoint::m_gamma [protected] |
Definition at line 109 of file b2WeldJoint.h.
b2Vec3 b2WeldJoint::m_impulse [protected] |
Definition at line 110 of file b2WeldJoint.h.
int32 b2WeldJoint::m_indexA [protected] |
Definition at line 113 of file b2WeldJoint.h.
int32 b2WeldJoint::m_indexB [protected] |
Definition at line 114 of file b2WeldJoint.h.
float32 b2WeldJoint::m_invIA [protected] |
Definition at line 121 of file b2WeldJoint.h.
float32 b2WeldJoint::m_invIB [protected] |
Definition at line 122 of file b2WeldJoint.h.
float32 b2WeldJoint::m_invMassA [protected] |
Definition at line 119 of file b2WeldJoint.h.
float32 b2WeldJoint::m_invMassB [protected] |
Definition at line 120 of file b2WeldJoint.h.
b2Vec2 b2WeldJoint::m_localAnchorA [protected] |
Definition at line 106 of file b2WeldJoint.h.
b2Vec2 b2WeldJoint::m_localAnchorB [protected] |
Definition at line 107 of file b2WeldJoint.h.
b2Vec2 b2WeldJoint::m_localCenterA [protected] |
Definition at line 117 of file b2WeldJoint.h.
b2Vec2 b2WeldJoint::m_localCenterB [protected] |
Definition at line 118 of file b2WeldJoint.h.
b2Mat33 b2WeldJoint::m_mass [protected] |
Definition at line 123 of file b2WeldJoint.h.
b2Vec2 b2WeldJoint::m_rA [protected] |
Definition at line 115 of file b2WeldJoint.h.
b2Vec2 b2WeldJoint::m_rB [protected] |
Definition at line 116 of file b2WeldJoint.h.
float32 b2WeldJoint::m_referenceAngle [protected] |
Definition at line 108 of file b2WeldJoint.h.