SO3Engine
|
Ball and Socket joint. More...
#include <OgreNewt_BasicJoints.h>
Public Member Functions | |
BallAndSocketLimits (const OgreNewt::Body *child, const OgreNewt::Body *parent, const Ogre::Vector3 &pos) | |
constructor | |
~BallAndSocketLimits () | |
destructor. | |
Ogre::Vector3 | getJointAngle () |
retrieve the current joint angle | |
Ogre::Vector3 | getJointOmega () |
retrieve the current joint omega | |
Ogre::Vector3 | getJointForce () |
retrieve the current joint force. | |
void | setLimits (Ogre::Radian maxCone, Ogre::Radian minTwist, Ogre::Radian maxTwist) |
set limits for the joints rotation | |
Public Member Functions inherited from OgreNewt::Joint | |
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 | |
Additional Inherited Members | |
Protected Member Functions inherited from OgreNewt::Joint | |
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 inherited from OgreNewt::Joint | |
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 inherited from OgreNewt::Joint | |
CustomJoint * | m_joint |
Detailed Description
Ball and Socket joint.
simple ball and socket joint, with limits.
Definition at line 27 of file OgreNewt_BasicJoints.h.
Constructor & Destructor Documentation
◆ BallAndSocketLimits()
OgreNewt::BallAndSocketLimits::BallAndSocketLimits | ( | const OgreNewt::Body * | child, |
const OgreNewt::Body * | parent, | ||
const Ogre::Vector3 & | pos | ||
) |
constructor
- Parameters
-
child pointer to the child rigid body. parent pointer to the parent rigid body. pass NULL to make the world itself the parent (aka a rigid joint) pos position of the joint in global space
Definition at line 21 of file OgreNewt_BasicJoints.cpp.
◆ ~BallAndSocketLimits()
OgreNewt::BallAndSocketLimits::~BallAndSocketLimits | ( | ) |
destructor.
Definition at line 34 of file OgreNewt_BasicJoints.cpp.
Member Function Documentation
◆ getJointAngle()
Ogre::Vector3 OgreNewt::BallAndSocketLimits::getJointAngle | ( | ) |
retrieve the current joint angle
Definition at line 46 of file OgreNewt_BasicJoints.cpp.
◆ getJointForce()
Ogre::Vector3 OgreNewt::BallAndSocketLimits::getJointForce | ( | ) |
retrieve the current joint force.
This can be used to find the "stress" on the joint. you can do special effects like break the joint if the force exceedes some value, etc.
Definition at line 74 of file OgreNewt_BasicJoints.cpp.
◆ getJointOmega()
Ogre::Vector3 OgreNewt::BallAndSocketLimits::getJointOmega | ( | ) |
retrieve the current joint omega
Definition at line 60 of file OgreNewt_BasicJoints.cpp.
◆ setLimits()
void OgreNewt::BallAndSocketLimits::setLimits | ( | Ogre::Radian | maxCone, |
Ogre::Radian | minTwist, | ||
Ogre::Radian | maxTwist | ||
) |
set limits for the joints rotation
- Parameters
-
pin pin direction in global space maxCone max angle for "swing" (in radians) maxTwist max angle for "twist" (in radians)
Definition at line 39 of file OgreNewt_BasicJoints.cpp.
The documentation for this class was generated from the following files:
- include/External/ogrenewt/OgreNewt_BasicJoints.h
- src/External/ogrenewt/OgreNewt_BasicJoints.cpp
Generated by 1.9.8