b2RevoluteJoint Class Reference
#include <b2RevoluteJoint.h>
List of all members.
Detailed Description
A revolute joint constrains two bodies to share a common point while they are free to rotate about the point. The relative rotation about the shared point is the joint angle. You can limit the relative rotation with a joint limit that specifies a lower and upper angle. You can use a motor to drive the relative rotation about the shared point. A maximum motor torque is provided so that infinite forces are not generated.
Constructor & Destructor Documentation
Member Function Documentation
| void b2RevoluteJoint::EnableLimit |
( |
bool |
flag |
) |
|
Enable/disable the joint limit.
| void b2RevoluteJoint::EnableMotor |
( |
bool |
flag |
) |
|
Enable/disable the joint motor.
| b2Vec2 b2RevoluteJoint::GetAnchorA |
( |
|
) |
const [virtual] |
Get the anchor point on bodyA in world coordinates.
Implements b2Joint.
| b2Vec2 b2RevoluteJoint::GetAnchorB |
( |
|
) |
const [virtual] |
Get the anchor point on bodyB in world coordinates.
Implements b2Joint.
| float32 b2RevoluteJoint::GetJointAngle |
( |
|
) |
const |
Get the current joint angle in radians.
| float32 b2RevoluteJoint::GetJointSpeed |
( |
|
) |
const |
Get the current joint angle speed in radians per second.
| float32 b2RevoluteJoint::GetLowerLimit |
( |
|
) |
const |
Get the lower joint limit in radians.
| float32 b2RevoluteJoint::GetMotorSpeed |
( |
|
) |
const [inline] |
Get the motor speed in radians per second.
| float32 b2RevoluteJoint::GetMotorTorque |
( |
|
) |
const |
Get the current motor torque, usually in N-m.
| b2Vec2 b2RevoluteJoint::GetReactionForce |
( |
float32 |
inv_dt |
) |
const [virtual] |
Get the reaction force on body2 at the joint anchor in Newtons.
Implements b2Joint.
| float32 b2RevoluteJoint::GetReactionTorque |
( |
float32 |
inv_dt |
) |
const [virtual] |
Get the reaction torque on body2 in N*m.
Implements b2Joint.
| float32 b2RevoluteJoint::GetUpperLimit |
( |
|
) |
const |
Get the upper joint limit in radians.
| void b2RevoluteJoint::InitVelocityConstraints |
( |
const b2TimeStep & |
step |
) |
[protected, virtual] |
| bool b2RevoluteJoint::IsLimitEnabled |
( |
|
) |
const |
Is the joint limit enabled?
| bool b2RevoluteJoint::IsMotorEnabled |
( |
|
) |
const |
Is the joint motor enabled?
Set the joint limits in radians.
| void b2RevoluteJoint::SetMaxMotorTorque |
( |
float32 |
torque |
) |
|
Set the maximum motor torque, usually in N-m.
| void b2RevoluteJoint::SetMotorSpeed |
( |
float32 |
speed |
) |
|
Set the motor speed in radians per second.
| bool b2RevoluteJoint::SolvePositionConstraints |
( |
float32 |
baumgarte |
) |
[protected, virtual] |
| void b2RevoluteJoint::SolveVelocityConstraints |
( |
const b2TimeStep & |
step |
) |
[protected, virtual] |
Friends And Related Function Documentation
Member Data Documentation
The documentation for this class was generated from the following files: