Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members

oxygen::HingeJoint Class Reference

#include <hingejoint.h>

Inheritance diagram for oxygen::HingeJoint:

Inheritance graph
[legend]
Collaboration diagram for oxygen::HingeJoint:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 HingeJoint ()
virtual ~HingeJoint ()
void SetAnchor (const salt::Vector3f &anchor)
 sets the joint anchor point.
salt::Vector3f GetAnchor (EBodyIndex idx)
 returns the joint anchor point in local coordinates on one of the two bodies.
void SetAxis (EAxisIndex idx)
 Sets the joint axis.
salt::Vector3f GetAxis ()
 Returns the hinge axis in the local coordinate system.
float GetAngle ()
 returns the hinge angle in degrees, measured between the two bodies, or between the body and the static environment.
float GetAngleRate ()
 returns the time derivate of the hinge angle
virtual void SetParameter (int parameter, float value)
 sets a joint parameter value
virtual float GetParameter (int parameter)
 returns a joint parameter value

Protected Member Functions

virtual void OnLink ()
 creates a new hingejoint joint

Detailed Description

Definition at line 29 of file hingejoint.h.


Constructor & Destructor Documentation

HingeJoint::HingeJoint  ) 
 

Definition at line 27 of file hingejoint.cpp.

HingeJoint::~HingeJoint  )  [virtual]
 

Definition at line 31 of file hingejoint.cpp.


Member Function Documentation

Vector3f HingeJoint::GetAnchor EBodyIndex  idx  ) 
 

returns the joint anchor point in local coordinates on one of the two bodies.

If the joint is perfectly satisfied, the joint anchor point will be the same for both bodies.

Definition at line 53 of file hingejoint.cpp.

References oxygen::Joint::BI_FIRST, oxygen::Joint::BI_SECOND, oxygen::BaseNode::GetLocalPos(), and oxygen::Joint::mODEJoint.

Here is the call graph for this function:

float HingeJoint::GetAngle  ) 
 

returns the hinge angle in degrees, measured between the two bodies, or between the body and the static environment.

Definition at line 117 of file hingejoint.cpp.

References salt::gRadToDeg(), and oxygen::Joint::mODEJoint.

Here is the call graph for this function:

float HingeJoint::GetAngleRate  ) 
 

returns the time derivate of the hinge angle

Definition at line 122 of file hingejoint.cpp.

References salt::gRadToDeg(), and oxygen::Joint::mODEJoint.

Here is the call graph for this function:

Vector3f HingeJoint::GetAxis  ) 
 

Returns the hinge axis in the local coordinate system.

Definition at line 110 of file hingejoint.cpp.

References oxygen::Joint::mODEJoint.

float HingeJoint::GetParameter int  parameter  )  [virtual]
 

returns a joint parameter value

Implements oxygen::Joint.

Definition at line 132 of file hingejoint.cpp.

References oxygen::Joint::mODEJoint.

void HingeJoint::OnLink  )  [protected, virtual]
 

creates a new hingejoint joint

Reimplemented from oxygen::Joint.

Definition at line 35 of file hingejoint.cpp.

References oxygen::ODEObject::GetWorldID(), and oxygen::Joint::mODEJoint.

Here is the call graph for this function:

void HingeJoint::SetAnchor const salt::Vector3f anchor  ) 
 

sets the joint anchor point.

The joint will try to keep this point on each body together. The input is specified in local coordinates.

Definition at line 46 of file hingejoint.cpp.

References oxygen::BaseNode::GetWorldTransform(), and oxygen::Joint::mODEJoint.

Here is the call graph for this function:

void HingeJoint::SetAxis EAxisIndex  idx  ) 
 

Sets the joint axis.

The connected bodies movements will be constrained to move around this axis.

Definition at line 80 of file hingejoint.cpp.

References oxygen::Joint::AI_FIRST, oxygen::Joint::AI_SECOND, oxygen::Joint::AI_THIRD, oxygen::BaseNode::GetWorldTransform(), and oxygen::Joint::mODEJoint.

Here is the call graph for this function:

void HingeJoint::SetParameter int  parameter,
float  value
[virtual]
 

sets a joint parameter value

Implements oxygen::Joint.

Definition at line 127 of file hingejoint.cpp.

References oxygen::Joint::mODEJoint.


The documentation for this class was generated from the following files:
Generated on Thu Apr 6 15:45:50 2006 for rcssserver3d by  doxygen 1.4.4