SO3Engine
|
base class for all joints. More...
#include <OgreNewt_Joint.h>
Public Member Functions | |
Joint () | |
constructor | |
virtual | ~Joint () |
destructor | |
Body * | getBody0 () const |
get the pointer to the first rigid body | |
Body * | getBody1 () const |
get the pointer to the first rigid body | |
const OgreNewt::World * | getWorld () |
get the pointer to the world | |
virtual void | submitConstraint (Ogre::Real timeStep, int threadIndex) |
must be define for a functioning joint. | |
virtual void | showDebugData (Ogre::SceneNode *debugRootNode) |
show joint visual debugging data | |
int | getCollisionState () const |
returns collision state | |
void | setCollisionState (int state) const |
sets the collision state | |
Ogre::Real | getStiffness () const |
get joint stiffness | |
void | setStiffness (Ogre::Real stiffness) const |
set joint stiffness | |
Protected Member Functions | |
void | addLinearRow (const Ogre::Vector3 &pt0, const Ogre::Vector3 &pt1, const Ogre::Vector3 &dir) const |
void | addAngularRow (Ogre::Radian relativeAngleError, const Ogre::Vector3 &dir) const |
void | addGeneralRow (const Ogre::Vector3 &linear0, const Ogre::Vector3 &angular0, const Ogre::Vector3 &linear1, const Ogre::Vector3 &angular1) const |
void | setRowMinimumFriction (Ogre::Real friction) const |
void | setRowMaximumFriction (Ogre::Real friction) const |
void | setRowStiffness (Ogre::Real stiffness) const |
void | setRowAcceleration (Ogre::Real accel) const |
void | setRowSpringDamper (Ogre::Real springK, Ogre::Real springD) const |
void | SetSupportJoint (CustomJoint *supportJoint) |
SetSupportJoint. | |
CustomJoint * | GetSupportJoint () const |
GetSupportJoint. | |
Static Protected Member Functions | |
static void _CDECL | destructorCallback (const CustomJoint *me) |
joint destructor callback glue | |
static void _CDECL | submitConstraintCallback (const CustomJoint *me, dFloat timestep, int threadIndex) |
submintContraint | |
Protected Attributes | |
CustomJoint * | m_joint |
base class for all joints.
this class is inherited by all other specific joint types.
Definition at line 30 of file OgreNewt_Joint.h.
OgreNewt::Joint::Joint | ( | ) |
constructor
Definition at line 13 of file OgreNewt_Joint.cpp.
|
virtual |
destructor
Definition at line 18 of file OgreNewt_Joint.cpp.
|
protected |
Definition at line 89 of file OgreNewt_Joint.cpp.
|
protected |
Definition at line 94 of file OgreNewt_Joint.cpp.
|
protected |
These functions are for applications who want to extend existing joint or to create entire new joint from scratch
Definition at line 84 of file OgreNewt_Joint.cpp.
|
staticprotected |
Body * OgreNewt::Joint::getBody0 | ( | ) | const |
get the pointer to the first rigid body
Definition at line 44 of file OgreNewt_Joint.cpp.
Body * OgreNewt::Joint::getBody1 | ( | ) | const |
get the pointer to the first rigid body
Definition at line 57 of file OgreNewt_Joint.cpp.
int OgreNewt::Joint::getCollisionState | ( | ) | const |
returns collision state
The collision state determines whether collision should be calculated between the parent and child bodies of the joint.
Definition at line 143 of file OgreNewt_Joint.cpp.
Ogre::Real OgreNewt::Joint::getStiffness | ( | ) | const |
get joint stiffness
Joint stiffness adjusts how much "play" the joint can have. high stiffness = very small play, but more likely to become unstable.
Definition at line 153 of file OgreNewt_Joint.cpp.
|
protected |
GetSupportJoint.
Definition at line 38 of file OgreNewt_Joint.cpp.
const OgreNewt::World * OgreNewt::Joint::getWorld | ( | ) |
get the pointer to the world
Definition at line 70 of file OgreNewt_Joint.cpp.
void OgreNewt::Joint::setCollisionState | ( | int | state | ) | const |
sets the collision state
The collision state determines whether collision should be calculated between the parent and child bodies of the joint.
state | integer value. 1 = collision on, 0 = collision off. |
Definition at line 148 of file OgreNewt_Joint.cpp.
|
protected |
Definition at line 128 of file OgreNewt_Joint.cpp.
|
protected |
Definition at line 122 of file OgreNewt_Joint.cpp.
|
protected |
Definition at line 116 of file OgreNewt_Joint.cpp.
|
protected |
Definition at line 138 of file OgreNewt_Joint.cpp.
|
protected |
Definition at line 133 of file OgreNewt_Joint.cpp.
void OgreNewt::Joint::setStiffness | ( | Ogre::Real | stiffness | ) | const |
set joint stiffness
Joint stiffness adjusts how much "play" the joint can have. high stiffness = very small play, but more likely to become unstable.
stiffness | float representing joint stiffness in range [0,1] |
Definition at line 158 of file OgreNewt_Joint.cpp.
|
protected |
SetSupportJoint.
Definition at line 29 of file OgreNewt_Joint.cpp.
|
inlinevirtual |
show joint visual debugging data
this function is called from the Debug display utility to show joint debug display information the function should be overridden by any derive class who wishes to show debug physics information for this joint in real time.
Reimplemented in OgreNewt::PlayerController, and OgreNewt::Vehicle.
Definition at line 57 of file OgreNewt_Joint.h.
|
inlinevirtual |
must be define for a functioning joint.
Reimplemented in OgreNewt::Hinge, OgreNewt::Slider, OgreNewt::PrebuiltCustomJoints::Custom2DJoint, and OgreNewt::PrebuiltCustomJoints::CustomRigidJoint.
Definition at line 50 of file OgreNewt_Joint.h.
|
staticprotected |
submintContraint
Definition at line 173 of file OgreNewt_Joint.cpp.
|
protected |
Definition at line 130 of file OgreNewt_Joint.h.