19 #ifndef B2_GEAR_JOINT_H
20 #define B2_GEAR_JOINT_H
22 #include <Box2D/Dynamics/Joints/b2Joint.h>
73 float32 GetRatio()
const;
107 float32 m_referenceAngleA;
108 float32 m_referenceAngleB;
116 int32 m_indexA, m_indexB, m_indexC, m_indexD;
117 b2Vec2 m_lcA, m_lcB, m_lcC, m_lcD;
118 float32 m_mA, m_mB, m_mC, m_mD;
119 float32 m_iA, m_iB, m_iC, m_iD;
121 float32 m_JwA, m_JwB, m_JwC, m_JwD;
void SetRatio(float32 ratio)
Set/Get the gear ratio.
Definition: b2GearJoint.cpp:392
b2Joint * joint1
The first revolute/prismatic joint attached to the gear joint.
Definition: b2GearJoint.h:37
b2Vec2 GetAnchorB() const
Get the anchor point on bodyB in world coordinates.
Definition: b2GearJoint.cpp:375
Definition: b2Joint.h:103
b2Vec2 GetAnchorA() const
Get the anchor point on bodyA in world coordinates.
Definition: b2GearJoint.cpp:370
b2Vec2 GetReactionForce(float32 inv_dt) const
Get the reaction force on bodyB at the joint anchor in Newtons.
Definition: b2GearJoint.cpp:380
Definition: b2GearJoint.h:56
b2Joint * joint2
The second revolute/prismatic joint attached to the gear joint.
Definition: b2GearJoint.h:40
float32 ratio
Definition: b2GearJoint.h:44
b2Joint * GetJoint1()
Get the first joint.
Definition: b2GearJoint.h:66
b2JointType type
The joint type is set automatically for concrete joint types.
Definition: b2Joint.h:86
Solver Data.
Definition: b2TimeStep.h:65
Joint definitions are used to construct joints.
Definition: b2Joint.h:74
float32 GetReactionTorque(float32 inv_dt) const
Get the reaction torque on bodyB in N*m.
Definition: b2GearJoint.cpp:386
A rigid body. These are created via b2World::CreateBody.
Definition: b2Body.h:132
void Dump()
Dump joint to dmLog.
Definition: b2GearJoint.cpp:403
A 2D column vector.
Definition: b2Math.h:56
Definition: b2GearJoint.h:26
b2Joint * GetJoint2()
Get the second joint.
Definition: b2GearJoint.h:69