a base interface providing common functionality for PhysX joints More...
#include <PxJoint.h>
Public Member Functions | |
virtual void | setActors (PxRigidActor *actor0, PxRigidActor *actor1)=0 |
Set the actors for this joint. More... | |
virtual void | getActors (PxRigidActor *&actor0, PxRigidActor *&actor1) const =0 |
Get the actors for this joint. More... | |
virtual void | setLocalPose (PxJointActorIndex::Enum actor, const PxTransform &localPose)=0 |
Set the joint local pose for an actor. More... | |
virtual PxTransform | getLocalPose (PxJointActorIndex::Enum actor) const =0 |
get the joint local pose for an actor. More... | |
virtual PxTransform | getRelativeTransform () const =0 |
get the relative pose for this joint More... | |
virtual PxVec3 | getRelativeLinearVelocity () const =0 |
get the relative linear velocity of the joint More... | |
virtual PxVec3 | getRelativeAngularVelocity () const =0 |
get the relative angular velocity of the joint More... | |
virtual void | setBreakForce (PxReal force, PxReal torque)=0 |
set the break force for this joint. More... | |
virtual void | getBreakForce (PxReal &force, PxReal &torque) const =0 |
get the break force for this joint. More... | |
virtual void | setConstraintFlags (PxConstraintFlags flags)=0 |
set the constraint flags for this joint. More... | |
virtual void | setConstraintFlag (PxConstraintFlag::Enum flag, bool value)=0 |
set a constraint flags for this joint to a specified value. More... | |
virtual PxConstraintFlags | getConstraintFlags () const =0 |
get the constraint flags for this joint. More... | |
virtual void | setInvMassScale0 (PxReal invMassScale)=0 |
set the inverse mass scale for actor0. More... | |
virtual PxReal | getInvMassScale0 () const =0 |
get the inverse mass scale for actor0. More... | |
virtual void | setInvInertiaScale0 (PxReal invInertiaScale)=0 |
set the inverse inertia scale for actor0. More... | |
virtual PxReal | getInvInertiaScale0 () const =0 |
get the inverse inertia scale for actor0. More... | |
virtual void | setInvMassScale1 (PxReal invMassScale)=0 |
set the inverse mass scale for actor1. More... | |
virtual PxReal | getInvMassScale1 () const =0 |
get the inverse mass scale for actor1. More... | |
virtual void | setInvInertiaScale1 (PxReal invInertiaScale)=0 |
set the inverse inertia scale for actor1. More... | |
virtual PxReal | getInvInertiaScale1 () const =0 |
get the inverse inertia scale for actor1. More... | |
virtual PxConstraint * | getConstraint () const =0 |
Retrieves the PxConstraint corresponding to this joint. More... | |
virtual void | setName (const char *name)=0 |
Sets a name string for the object that can be retrieved with getName(). More... | |
virtual const char * | getName () const =0 |
Retrieves the name string set with setName(). More... | |
virtual void | release ()=0 |
Deletes the joint. More... | |
virtual PxScene * | getScene () const =0 |
Retrieves the scene which this joint belongs to. More... | |
Public Member Functions inherited from PxBase | |
virtual const char * | getConcreteTypeName () const =0 |
Returns string name of dynamic type. More... | |
template<class T > | |
T * | is () |
template<class T > | |
const T * | is () const |
PX_FORCE_INLINE PxType | getConcreteType () const |
Returns concrete type of object. More... | |
PX_FORCE_INLINE void | setBaseFlag (PxBaseFlag::Enum flag, bool value) |
Set PxBaseFlag. More... | |
PX_FORCE_INLINE void | setBaseFlags (PxBaseFlags inFlags) |
Set PxBaseFlags. More... | |
PX_FORCE_INLINE PxBaseFlags | getBaseFlags () const |
Returns PxBaseFlags. More... | |
virtual bool | isReleasable () const |
Whether the object is subordinate. More... | |
Static Public Member Functions | |
static void | getBinaryMetaData (PxOutputStream &stream) |
Put class meta data in stream, used for serialization. More... | |
Public Attributes | |
void * | userData |
user can assign this to whatever, usually to create a 1:1 relationship with a user object. More... | |
Protected Member Functions | |
virtual | ~PxJoint () |
PX_INLINE | PxJoint (PxType concreteType, PxBaseFlags baseFlags) |
Constructor. More... | |
PX_INLINE | PxJoint (PxBaseFlags baseFlags) |
Deserialization constructor. More... | |
virtual bool | isKindOf (const char *name) const |
Returns whether a given type name matches with the type of this instance. More... | |
Protected Member Functions inherited from PxBase | |
PX_INLINE | PxBase (PxType concreteType, PxBaseFlags baseFlags) |
Constructor setting concrete type and base flags. More... | |
PX_INLINE | PxBase (PxBaseFlags baseFlags) |
Deserialization constructor setting base flags. More... | |
virtual | ~PxBase () |
Destructor. More... | |
template<class T > | |
bool | typeMatch () const |
Additional Inherited Members | |
Protected Attributes inherited from PxBase | |
PxType | mConcreteType |
PxBaseFlags | mBaseFlags |
a base interface providing common functionality for PhysX joints
|
inlineprotectedvirtual |
|
inlineprotected |
Constructor.
|
inlineprotected |
Deserialization constructor.
|
pure virtual |
Get the actors for this joint.
[out] | actor0 | the first actor. |
[out] | actor1 | the second actor |
|
static |
Put class meta data in stream, used for serialization.
|
pure virtual |
get the break force for this joint.
[out] | force | the maximum force the joint can apply before breaking |
[out] | torque | the maximum torque the joint can apply before breaking |
|
pure virtual |
Retrieves the PxConstraint corresponding to this joint.
This can be used to determine, among other things, the force applied at the joint.
|
pure virtual |
|
pure virtual |
get the inverse inertia scale for actor0.
|
pure virtual |
get the inverse inertia scale for actor1.
|
pure virtual |
get the inverse mass scale for actor0.
|
pure virtual |
get the inverse mass scale for actor1.
|
pure virtual |
get the joint local pose for an actor.
[in] | actor | 0 for the first actor, 1 for the second actor. |
return the local pose for this joint
|
pure virtual |
|
pure virtual |
get the relative angular velocity of the joint
This function returns the angular velocity of actor1 relative to actor0. The value is returned in the constraint frame of actor0
|
pure virtual |
get the relative linear velocity of the joint
This function returns the linear velocity of the origin of the constraint frame of actor1, relative to the origin of the constraint frame of actor0. The value is returned in the constraint frame of actor0
|
pure virtual |
get the relative pose for this joint
This function returns the pose of the joint frame of actor1 relative to actor0
|
pure virtual |
Retrieves the scene which this joint belongs to.
|
inlineprotectedvirtual |
Returns whether a given type name matches with the type of this instance.
Reimplemented from PxBase.
Reimplemented in PxD6Joint, PxRevoluteJoint, PxDistanceJoint, PxPrismaticJoint, PxSphericalJoint, PxContactJoint, and PxFixedJoint.
References PxBase::isKindOf().
Referenced by PxFixedJoint::isKindOf(), PxContactJoint::isKindOf(), PxSphericalJoint::isKindOf(), PxPrismaticJoint::isKindOf(), PxDistanceJoint::isKindOf(), PxRevoluteJoint::isKindOf(), and PxD6Joint::isKindOf().
|
pure virtual |
|
pure virtual |
Set the actors for this joint.
An actor may be NULL to indicate the world frame. At most one of the actors may be NULL.
[in] | actor0 | the first actor. |
[in] | actor1 | the second actor |
|
pure virtual |
set the break force for this joint.
if the constraint force or torque on the joint exceeds the specified values, the joint will break, at which point it will not constrain the two actors and the flag PxConstraintFlag::eBROKEN will be set. The force and torque are measured in the joint frame of the first actor
[in] | force | the maximum force the joint can apply before breaking |
[in] | torque | the maximum torque the joint can apply before breaking |
|
pure virtual |
set a constraint flags for this joint to a specified value.
[in] | flag | the constraint flag |
[in] | value | the value to which to set the flag |
|
pure virtual |
set the constraint flags for this joint.
[in] | flags | the constraint flags |
|
pure virtual |
set the inverse inertia scale for actor0.
[in] | invInertiaScale | the scale to apply to the inverse inertia of actor0 for resolving this constraint |
|
pure virtual |
set the inverse inertia scale for actor1.
[in] | invInertiaScale | the scale to apply to the inverse inertia of actor1 for resolving this constraint |
|
pure virtual |
set the inverse mass scale for actor0.
[in] | invMassScale | the scale to apply to the inverse mass of actor 0 for resolving this constraint |
|
pure virtual |
set the inverse mass scale for actor1.
[in] | invMassScale | the scale to apply to the inverse mass of actor 1 for resolving this constraint |
|
pure virtual |
Set the joint local pose for an actor.
This is the relative pose which locates the joint frame relative to the actor.
[in] | actor | 0 for the first actor, 1 for the second actor. |
[in] | localPose | the local pose for the actor this joint |
|
pure virtual |
void* PxJoint::userData |
user can assign this to whatever, usually to create a 1:1 relationship with a user object.