 |
Box2D
2.3.0
A 2D Physics Engine for Games
|
22 #include <Box2D/Common/b2Math.h>
78 type = e_unknownJoint;
147 virtual void Dump() {
b2Log(
"// Dump is not supported for this joint type.\n"); }
164 virtual void InitVelocityConstraints(
const b2SolverData& data) = 0;
165 virtual void SolveVelocityConstraints(
const b2SolverData& data) = 0;
168 virtual bool SolvePositionConstraints(
const b2SolverData& data) = 0;
181 bool m_collideConnected;
223 return m_collideConnected;
A 2D column vector.
Definition: b2Math.h:54
A rigid body. These are created via b2World::CreateBody.
Definition: b2Body.h:127
bool IsActive() const
Short-cut function to determine if either body is inactive.
Definition: b2Joint.cpp:208
virtual b2Vec2 GetReactionForce(float32 inv_dt) const =0
Get the reaction force on bodyB at the joint anchor in Newtons.
void * GetUserData() const
Get the user data pointer.
Definition: b2Joint.h:211
b2Body * GetBodyA()
Get the first body attached to this joint.
Definition: b2Joint.h:191
bool collideConnected
Set this flag to true if the attached bodies should collide.
Definition: b2Joint.h:98
virtual b2Vec2 GetAnchorA() const =0
Get the anchor point on bodyA in world coordinates.
virtual float32 GetReactionTorque(float32 inv_dt) const =0
Get the reaction torque on bodyB in N*m.
b2Body * GetBodyB()
Get the second body attached to this joint.
Definition: b2Joint.h:196
b2Joint * joint
the joint
Definition: b2Joint.h:68
Joint definitions are used to construct joints.
Definition: b2Joint.h:75
b2JointType type
The joint type is set automatically for concrete joint types.
Definition: b2Joint.h:86
void SetUserData(void *data)
Set the user data pointer.
Definition: b2Joint.h:216
b2JointType GetType() const
Get the type of the concrete joint.
Definition: b2Joint.h:186
bool GetCollideConnected() const
Definition: b2Joint.h:221
b2Body * bodyB
The second attached body.
Definition: b2Joint.h:95
virtual void Dump()
Dump this joint to the log file.
Definition: b2Joint.h:147
Definition: b2BlockAllocator.h:36
virtual void ShiftOrigin(const b2Vec2 &newOrigin)
Shift the origin for any points stored in world coordinates.
Definition: b2Joint.h:150
b2JointEdge * prev
the previous joint edge in the body's joint list
Definition: b2Joint.h:69
Definition: b2GearJoint.h:57
Solver Data.
Definition: b2TimeStep.h:64
b2JointEdge * next
the next joint edge in the body's joint list
Definition: b2Joint.h:70
virtual b2Vec2 GetAnchorB() const =0
Get the anchor point on bodyB in world coordinates.
b2Body * other
provides quick access to the other body attached.
Definition: b2Joint.h:67
void b2Log(const char *string,...)
Logging function.
Definition: b2Settings.cpp:38
b2Body * bodyA
The first attached body.
Definition: b2Joint.h:92
Definition: b2Joint.h:104
This is an internal class.
Definition: b2Island.h:35
void * userData
Use this to attach application specific data to your joints.
Definition: b2Joint.h:89
b2Joint * GetNext()
Get the next joint the world joint list.
Definition: b2Joint.h:201