List of all members
PxRigidDynamic Class Referenceabstract

PxRigidDynamic represents a dynamic rigid simulation object in the physics SDK. More...

#include <PxRigidDynamic.h>

Inheritance diagram for PxRigidDynamic:
Inheritance graph
[legend]
Collaboration diagram for PxRigidDynamic:
Collaboration graph
[legend]

Public Member Functions

Kinematic Actors
virtual void setKinematicTarget (const PxTransform &destination)=0
 Moves kinematically controlled dynamic actors through the game world. More...
 
virtual bool getKinematicTarget (PxTransform &target)=0
 Get target pose of a kinematically controlled dynamic actor. More...
 
Damping
virtual void setLinearDamping (PxReal linDamp)=0
 Sets the linear damping coefficient. More...
 
virtual PxReal getLinearDamping () const =0
 Retrieves the linear damping coefficient. More...
 
virtual void setAngularDamping (PxReal angDamp)=0
 Sets the angular damping coefficient. More...
 
virtual PxReal getAngularDamping () const =0
 Retrieves the angular damping coefficient. More...
 
Velocity
virtual void setMaxAngularVelocity (PxReal maxAngVel)=0
 Lets you set the maximum angular velocity permitted for this actor. More...
 
virtual PxReal getMaxAngularVelocity () const =0
 Retrieves the maximum angular velocity permitted for this actor. More...
 
- Public Member Functions inherited from PxRigidBody
virtual void setCMassLocalPose (const PxTransform &pose)=0
 Sets the pose of the center of mass relative to the actor. More...
 
virtual PxTransform getCMassLocalPose () const =0
 Retrieves the center of mass pose relative to the actor frame. More...
 
virtual void setMass (PxReal mass)=0
 Sets the mass of a dynamic actor. More...
 
virtual PxReal getMass () const =0
 Retrieves the mass of the actor. More...
 
virtual PxReal getInvMass () const =0
 Retrieves the inverse mass of the actor. More...
 
virtual void setMassSpaceInertiaTensor (const PxVec3 &m)=0
 Sets the inertia tensor, using a parameter specified in mass space coordinates. More...
 
virtual PxVec3 getMassSpaceInertiaTensor () const =0
 Retrieves the diagonal inertia tensor of the actor relative to the mass coordinate frame. More...
 
virtual PxVec3 getMassSpaceInvInertiaTensor () const =0
 Retrieves the diagonal inverse inertia tensor of the actor relative to the mass coordinate frame. More...
 
virtual PxVec3 getLinearVelocity () const =0
 Retrieves the linear velocity of an actor. More...
 
virtual void setLinearVelocity (const PxVec3 &linVel, bool autowake=true)=0
 Sets the linear velocity of the actor. More...
 
virtual PxVec3 getAngularVelocity () const =0
 Retrieves the angular velocity of the actor. More...
 
virtual void setAngularVelocity (const PxVec3 &angVel, bool autowake=true)=0
 Sets the angular velocity of the actor. More...
 
virtual void addForce (const PxVec3 &force, PxForceMode::Enum mode=PxForceMode::eFORCE, bool autowake=true)=0
 Applies a force (or impulse) defined in the global coordinate frame to the actor at its center of mass. More...
 
virtual void addTorque (const PxVec3 &torque, PxForceMode::Enum mode=PxForceMode::eFORCE, bool autowake=true)=0
 Applies an impulsive torque defined in the global coordinate frame to the actor. More...
 
virtual void clearForce (PxForceMode::Enum mode=PxForceMode::eFORCE)=0
 Clears the accumulated forces (sets the accumulated force back to zero). More...
 
virtual void clearTorque (PxForceMode::Enum mode=PxForceMode::eFORCE)=0
 Clears the impulsive torque defined in the global coordinate frame to the actor. More...
 
virtual PX_DEPRECATED void setRigidDynamicFlag (PxRigidDynamicFlag::Enum flag, bool value)=0
 Raises or clears a particular dynamic rigid body flag. More...
 
virtual PX_DEPRECATED void setRigidDynamicFlags (PxRigidDynamicFlags inFlags)=0
 
virtual void setRigidBodyFlag (PxRigidBodyFlag::Enum flag, bool value)=0
 Raises or clears a particular rigid body flag. More...
 
virtual void setRigidBodyFlags (PxRigidBodyFlags inFlags)=0
 
virtual PX_DEPRECATED
PxRigidDynamicFlags 
getRigidDynamicFlags () const =0
 Reads the PxRigidBody flags. More...
 
virtual PxRigidBodyFlags getRigidBodyFlags () const =0
 Reads the PxRigidBody flags. More...
 
virtual void setMinCCDAdvanceCoefficient (PxReal advanceCoefficient)=0
 Sets the CCD minimum advance coefficient. More...
 
virtual PxReal getMinCCDAdvanceCoefficient () const =0
 Gets the CCD minimum advance coefficient. More...
 
virtual void setMaxDepenetrationVelocity (const PxReal biasClamp)=0
 Sets the maximum depenetration velocity permitted to be introduced by the solver. This value controls how much velocity the solver can introduce to correct for penetrations in contacts. More...
 
virtual PxReal getMaxDepenetrationVelocity () const =0
 Returns the maximum depenetration velocity the solver is permitted to introduced. This value controls how much velocity the solver can introduce to correct for penetrations in contacts. More...
 
- Public Member Functions inherited from PxRigidActor
virtual void release ()=0
 Deletes the rigid actor object. More...
 
virtual PxTransform getGlobalPose () const =0
 Retrieves the actors world space transform. More...
 
virtual void setGlobalPose (const PxTransform &pose, bool autowake=true)=0
 Method for setting an actor's pose in the world. More...
 
virtual PxShapecreateShape (const PxGeometry &geometry, PxMaterial *const *materials, PxU16 materialCount, PxShapeFlags shapeFlags=PxShapeFlag::eVISUALIZATION|PxShapeFlag::eSCENE_QUERY_SHAPE|PxShapeFlag::eSIMULATION_SHAPE)=0
 Creates a new shape with default properties and a list of materials and adds it to the list of shapes of this actor. More...
 
PX_DEPRECATED PX_INLINE PxShapecreateShape (const PxGeometry &geometry, PxMaterial *const *materials, PxU32 materialCount, const PxTransform &localPose)
 Deprecated function to create shapes with an initial transform. More...
 
PX_FORCE_INLINE PxShapecreateShape (const PxGeometry &geometry, const PxMaterial &material, PxShapeFlags shapeFlags=PxShapeFlag::eVISUALIZATION|PxShapeFlag::eSCENE_QUERY_SHAPE|PxShapeFlag::eSIMULATION_SHAPE)
 Creates a new shape with default properties and a single material adds it to the list of shapes of this actor. More...
 
PX_DEPRECATED PX_INLINE PxShapecreateShape (const PxGeometry &geometry, const PxMaterial &material, const PxTransform &localPose)
 Deprecated function to create shapes with an initial transform. More...
 
virtual void attachShape (PxShape &shape)=0
 
virtual void detachShape (PxShape &shape, bool wakeOnLostTouch=true)=0
 
virtual PxU32 getNbShapes () const =0
 Returns the number of shapes assigned to the actor. More...
 
virtual PxU32 getShapes (PxShape **userBuffer, PxU32 bufferSize, PxU32 startIndex=0) const =0
 Retrieve all the shape pointers belonging to the actor. More...
 
virtual PxU32 getNbConstraints () const =0
 Returns the number of constraint shaders attached to the actor. More...
 
virtual PxU32 getConstraints (PxConstraint **userBuffer, PxU32 bufferSize, PxU32 startIndex=0) const =0
 Retrieve all the constraint shader pointers belonging to the actor. More...
 
- Public Member Functions inherited from PxActor
virtual PxActorType::Enum getType () const =0
 Retrieves the type of actor. More...
 
PX_DEPRECATED PX_INLINE
PxRigidStatic
isRigidStatic ()
 Attempts to cast to specific actor type. More...
 
PX_DEPRECATED PX_INLINE const
PxRigidStatic
isRigidStatic () const
 
PX_DEPRECATED PX_INLINE
PxRigidDynamic
isRigidDynamic ()
 
PX_DEPRECATED PX_INLINE const
PxRigidDynamic
isRigidDynamic () const
 
PX_DEPRECATED PX_INLINE
PxParticleSystem
isParticleSystem ()
 
PX_DEPRECATED PX_INLINE const
PxParticleSystem
isParticleSystem () const
 
PX_DEPRECATED PX_INLINE
PxParticleFluid
isParticleFluid ()
 
PX_DEPRECATED PX_INLINE const
PxParticleFluid
isParticleFluid () const
 
PX_DEPRECATED PX_INLINE
PxArticulationLink
isArticulationLink ()
 
PX_DEPRECATED PX_INLINE const
PxArticulationLink
isArticulationLink () const
 
PX_DEPRECATED PX_INLINE PxClothisCloth ()
 
PX_DEPRECATED PX_INLINE const
PxCloth
isCloth () const
 
PX_DEPRECATED PX_INLINE
PxRigidActor
isRigidActor ()
 
PX_DEPRECATED PX_INLINE const
PxRigidActor
isRigidActor () const
 
PX_DEPRECATED PX_INLINE
PxRigidBody
isRigidBody ()
 
PX_DEPRECATED PX_INLINE const
PxRigidBody
isRigidBody () const
 
PX_DEPRECATED PX_INLINE
PxParticleBase
isParticleBase ()
 
PX_DEPRECATED PX_INLINE const
PxParticleBase
isParticleBase () const
 
virtual PxScenegetScene () const =0
 Retrieves the scene which this actor belongs to. 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 PxBounds3 getWorldBounds (float inflation=1.01f) const =0
 Retrieves the axis aligned bounding box enclosing the actor. More...
 
virtual void setActorFlag (PxActorFlag::Enum flag, bool value)=0
 Raises or clears a particular actor flag. More...
 
virtual void setActorFlags (PxActorFlags inFlags)=0
 sets the actor flags More...
 
virtual PxActorFlags getActorFlags () const =0
 Reads the PxActor flags. More...
 
virtual void setDominanceGroup (PxDominanceGroup dominanceGroup)=0
 Assigns dynamic actors a dominance group identifier. More...
 
virtual PxDominanceGroup getDominanceGroup () const =0
 Retrieves the value set with setDominanceGroup(). More...
 
virtual void setOwnerClient (PxClientID inClient)=0
 Sets the owner client of an actor. More...
 
virtual PxClientID getOwnerClient () const =0
 Returns the owner client that was specified with at creation time. More...
 
virtual void setClientBehaviorFlags (PxActorClientBehaviorFlags)=0
 Sets the behavior bits of the actor. More...
 
virtual PxActorClientBehaviorFlags getClientBehaviorFlags () const =0
 Retrieves the behavior bits of the actor. More...
 
virtual PxAggregategetAggregate () const =0
 Retrieves the aggregate the actor might be a part of. More...
 
- Public Member Functions inherited from PxBase
template<class T >
T * is ()
 
template<class T >
const T * is () const
 
PX_INLINE PxType getConcreteType () const
 Returns concrete type of object. More...
 
PX_INLINE void setBaseFlag (PxBaseFlag::Enum flag, bool value)
 Set PxBaseFlag. More...
 
PX_INLINE void setBaseFlags (PxBaseFlags inFlags)
 Set PxBaseFlags. More...
 
PX_INLINE PxBaseFlags getBaseFlags () const
 Returns PxBaseFlags. More...
 
virtual bool isReleasable () const
 Whether the object is subordinate. More...
 

Sleeping

virtual bool isSleeping () const =0
 Returns true if this body is sleeping. More...
 
virtual void setSleepThreshold (PxReal threshold)=0
 Sets the mass-normalized kinetic energy threshold below which an actor may go to sleep. More...
 
virtual PxReal getSleepThreshold () const =0
 Returns the mass-normalized kinetic energy below which an actor may go to sleep. More...
 
virtual void setStabilizationThreshold (PxReal threshold)=0
 Sets the mass-normalized kinetic energy threshold below which an actor may participate in stabilization. More...
 
virtual PxReal getStabilizationThreshold () const =0
 Returns the mass-normalized kinetic energy below which an actor may participate in stabilization. More...
 
virtual void setWakeCounter (PxReal wakeCounterValue)=0
 Sets the wake counter for the actor. More...
 
virtual PxReal getWakeCounter () const =0
 Returns the wake counter of the actor. More...
 
virtual void wakeUp ()=0
 Wakes up the actor if it is sleeping. More...
 
virtual void putToSleep ()=0
 Forces the actor to sleep. More...
 
virtual void setSolverIterationCounts (PxU32 minPositionIters, PxU32 minVelocityIters=1)=0
 Sets the solver iteration counts for the body. More...
 
virtual void getSolverIterationCounts (PxU32 &minPositionIters, PxU32 &minVelocityIters) const =0
 Retrieves the solver iteration counts. More...
 
virtual PxReal getContactReportThreshold () const =0
 Retrieves the force threshold for contact reports. More...
 
virtual void setContactReportThreshold (PxReal threshold)=0
 Sets the force threshold for contact reports. More...
 
virtual const char * getConcreteTypeName () const
 Returns string name of dynamic type. More...
 
PX_INLINE PxRigidDynamic (PxType concreteType, PxBaseFlags baseFlags)
 
PX_INLINE PxRigidDynamic (PxBaseFlags baseFlags)
 
virtual ~PxRigidDynamic ()
 
virtual bool isKindOf (const char *name) const
 Returns whether a given type name matches with the type of this instance. More...
 

Additional Inherited Members

- Public Attributes inherited from PxActor
void * userData
 user can assign this to whatever, usually to create a 1:1 relationship with a user object. More...
 
- Protected Member Functions inherited from PxRigidBody
PX_INLINE PxRigidBody (PxType concreteType, PxBaseFlags baseFlags)
 
PX_INLINE PxRigidBody (PxBaseFlags baseFlags)
 
virtual ~PxRigidBody ()
 
- Protected Member Functions inherited from PxRigidActor
PX_INLINE PxRigidActor (PxType concreteType, PxBaseFlags baseFlags)
 
PX_INLINE PxRigidActor (PxBaseFlags baseFlags)
 
virtual ~PxRigidActor ()
 
- Protected Member Functions inherited from PxActor
PX_INLINE PxActor (PxType concreteType, PxBaseFlags baseFlags)
 
PX_INLINE PxActor (PxBaseFlags baseFlags)
 
virtual ~PxActor ()
 
- Protected Attributes inherited from PxBase
PxType mConcreteType
 
PxBaseFlags mBaseFlags
 

Detailed Description

PxRigidDynamic represents a dynamic rigid simulation object in the physics SDK.

Creation

Instances of this class are created by calling PxPhysics::createRigidDynamic() and deleted with release().

Visualizations

See Also
PxRigidBody PxPhysics.createRigidDynamic() release()

Constructor & Destructor Documentation

PX_INLINE PxRigidDynamic::PxRigidDynamic ( PxType  concreteType,
PxBaseFlags  baseFlags 
)
inlineprotected
PX_INLINE PxRigidDynamic::PxRigidDynamic ( PxBaseFlags  baseFlags)
inlineprotected
virtual PxRigidDynamic::~PxRigidDynamic ( )
inlineprotectedvirtual

Member Function Documentation

virtual PxReal PxRigidDynamic::getAngularDamping ( ) const
pure virtual

Retrieves the angular damping coefficient.

Returns
The angular damping coefficient associated with this actor.
See Also
setAngularDamping() getLinearDamping()
virtual const char* PxRigidDynamic::getConcreteTypeName ( ) const
inlinevirtual

Returns string name of dynamic type.

Returns
Class name of most derived type of this object.

Reimplemented from PxBase.

virtual PxReal PxRigidDynamic::getContactReportThreshold ( ) const
pure virtual

Retrieves the force threshold for contact reports.

The contact report threshold is a force threshold. If the force between two actors exceeds this threshold for either of the two actors, a contact report will be generated according to the contact report threshold flags provided by the filter shader/callback. See PxPairFlag.

The threshold used for a collision between a dynamic actor and the static environment is the threshold of the dynamic actor, and all contacts with static actors are summed to find the total normal force.

Default: PX_MAX_F32

Returns
Force threshold for contact reports.
See Also
setContactReportThreshold PxPairFlag PxSimulationFilterShader PxSimulationFilterCallback
virtual bool PxRigidDynamic::getKinematicTarget ( PxTransform target)
pure virtual

Get target pose of a kinematically controlled dynamic actor.

Parameters
[out]targetTransform to write the target pose to. Only valid if the method returns true.
Returns
True if the actor is a kinematically controlled dynamic and the target has been set, else False.
See Also
setKinematicTarget() PxRigidBodyFlag setRigidBodyFlag()
virtual PxReal PxRigidDynamic::getLinearDamping ( ) const
pure virtual

Retrieves the linear damping coefficient.

Returns
The linear damping coefficient associated with this actor.
See Also
setLinearDamping() getAngularDamping()
virtual PxReal PxRigidDynamic::getMaxAngularVelocity ( ) const
pure virtual

Retrieves the maximum angular velocity permitted for this actor.

Returns
The maximum allowed angular velocity for this actor.
See Also
setMaxAngularVelocity
virtual PxReal PxRigidDynamic::getSleepThreshold ( ) const
pure virtual

Returns the mass-normalized kinetic energy below which an actor may go to sleep.

Returns
The energy threshold for sleeping.
See Also
isSleeping() wakeUp() putToSleep() setSleepThreshold()
virtual void PxRigidDynamic::getSolverIterationCounts ( PxU32 minPositionIters,
PxU32 minVelocityIters 
) const
pure virtual

Retrieves the solver iteration counts.

See Also
setSolverIterationCounts()
virtual PxReal PxRigidDynamic::getStabilizationThreshold ( ) const
pure virtual

Returns the mass-normalized kinetic energy below which an actor may participate in stabilization.

Actors whose kinetic energy divided by their mass is above this threshold will not participate in stabilization.

Returns
The energy threshold for participating in stabilization.
See Also
setStabilizationThreshold() PxSceneFlag::eENABLE_STABILIZATION
virtual PxReal PxRigidDynamic::getWakeCounter ( ) const
pure virtual

Returns the wake counter of the actor.

Returns
The wake counter of the actor.
See Also
isSleeping() setWakeCounter()
virtual bool PxRigidDynamic::isKindOf ( const char *  superClass) const
inlineprotectedvirtual

Returns whether a given type name matches with the type of this instance.

Reimplemented from PxRigidBody.

References PxRigidBody::isKindOf().

virtual bool PxRigidDynamic::isSleeping ( ) const
pure virtual

Returns true if this body is sleeping.

When an actor does not move for a period of time, it is no longer simulated in order to save time. This state is called sleeping. However, because the object automatically wakes up when it is either touched by an awake object, or one of its properties is changed by the user, the entire sleep mechanism should be transparent to the user.

In general, a dynamic rigid actor is guaranteed to be awake if at least one of the following holds:

  • The wake counter is positive (see setWakeCounter()).
  • The linear or angular velocity is non-zero.
  • A non-zero force or torque has been applied.

If a dynamic rigid actor is sleeping, the following state is guaranteed:

  • The wake counter is zero.
  • The linear and angular velocity is zero.
  • There is no force update pending.

When an actor gets inserted into a scene, it will be considered asleep if all the points above hold, else it will be treated as awake.

If an actor is asleep after the call to PxScene::fetchResults() returns, it is guaranteed that the pose of the actor was not changed. You can use this information to avoid updating the transforms of associated objects.

Note
A kinematic actor is asleep unless a target pose has been set (in which case it will stay awake until the end of the next simulation step where no target pose has been set anymore). The wake counter will get set to zero or to the reset value PxSceneDesc::wakeCounterResetValue in the case where a target pose has been set to be consistent with the definitions above.
It is invalid to use this method if the actor has not been added to a scene already.
Returns
True if the actor is sleeping.
See Also
isSleeping() wakeUp() putToSleep() getSleepThreshold()
virtual void PxRigidDynamic::putToSleep ( )
pure virtual

Forces the actor to sleep.

The actor will stay asleep during the next simulation step if not touched by another non-sleeping actor.

Note
Any applied force will be cleared and the velocity and the wake counter of the actor will be set to 0.
It is invalid to use this method if the actor has not been added to a scene already or if PxActorFlag::eDISABLE_SIMULATION is set.
It is invalid to use this method for kinematic actors since the sleep state for kinematics is defined based on whether a target pose has been set (see the comment in isSleeping()).
See Also
isSleeping() wakeUp()
virtual void PxRigidDynamic::setAngularDamping ( PxReal  angDamp)
pure virtual

Sets the angular damping coefficient.

Zero represents no damping.

The angular damping coefficient must be nonnegative.

Default: 0.05

Parameters
[in]angDampAngular damping coefficient. Range: [0, PX_MAX_F32)
See Also
getAngularDamping() setLinearDamping()
virtual void PxRigidDynamic::setContactReportThreshold ( PxReal  threshold)
pure virtual

Sets the force threshold for contact reports.

See getContactReportThreshold().

Parameters
[in]thresholdForce threshold for contact reports. Range: [0, PX_MAX_F32)
See Also
getContactReportThreshold PxPairFlag
virtual void PxRigidDynamic::setKinematicTarget ( const PxTransform destination)
pure virtual

Moves kinematically controlled dynamic actors through the game world.

You set a dynamic actor to be kinematic using the PxRigidBodyFlag::eKINEMATIC flag with setRigidBodyFlag().

The move command will result in a velocity that will move the body into the desired pose. After the move is carried out during a single time step, the velocity is returned to zero. Thus, you must continuously call this in every time step for kinematic actors so that they move along a path.

This function simply stores the move destination until the next simulation step is processed, so consecutive calls will simply overwrite the stored target variable.

The motion is always fully carried out.

Note
It is invalid to use this method if the actor has not been added to a scene already or if PxActorFlag::eDISABLE_SIMULATION is set.

Sleeping: This call wakes the actor if it is sleeping and will set the wake counter to PxSceneDesc::wakeCounterResetValue.

Parameters
[in]destinationThe desired pose for the kinematic actor, in the global frame. Range: rigid body transform.
See Also
getKinematicTarget() PxRigidBodyFlag setRigidBodyFlag()
virtual void PxRigidDynamic::setLinearDamping ( PxReal  linDamp)
pure virtual

Sets the linear damping coefficient.

Zero represents no damping. The damping coefficient must be nonnegative.

Default: 0.0

Parameters
[in]linDampLinear damping coefficient. Range: [0, PX_MAX_F32)
See Also
getLinearDamping() setAngularDamping()
virtual void PxRigidDynamic::setMaxAngularVelocity ( PxReal  maxAngVel)
pure virtual

Lets you set the maximum angular velocity permitted for this actor.

For various internal computations, very quickly rotating actors introduce error into the simulation, which leads to undesired results.

With this function, you can set the maximum angular velocity permitted for this rigid body. Higher angular velocities are clamped to this value.

Note: The angular velocity is clamped to the set value before the solver, which means that the limit may still be momentarily exceeded.

Default: 7.0

Parameters
[in]maxAngVelMax allowable angular velocity for actor. Range: [0, PX_MAX_F32)
See Also
getMaxAngularVelocity()
virtual void PxRigidDynamic::setSleepThreshold ( PxReal  threshold)
pure virtual

Sets the mass-normalized kinetic energy threshold below which an actor may go to sleep.

Actors whose kinetic energy divided by their mass is below this threshold will be candidates for sleeping.

Default: 5e-5f * PxTolerancesScale::speed * PxTolerancesScale::speed

Parameters
[in]thresholdEnergy below which an actor may go to sleep. Range: [0, PX_MAX_F32)
See Also
isSleeping() getSleepThreshold() wakeUp() putToSleep() PxTolerancesScale
virtual void PxRigidDynamic::setSolverIterationCounts ( PxU32  minPositionIters,
PxU32  minVelocityIters = 1 
)
pure virtual

Sets the solver iteration counts for the body.

The solver iteration count determines how accurately joints and contacts are resolved. If you are having trouble with jointed bodies oscillating and behaving erratically, then setting a higher position iteration count may improve their stability.

If intersecting bodies are being depenetrated too violently, increase the number of velocity iterations. More velocity iterations will drive the relative exit velocity of the intersecting objects closer to the correct value given the restitution.

Default: 4 position iterations, 1 velocity iteration

Parameters
[in]minPositionItersNumber of position iterations the solver should perform for this body. Range: [1,255]
[in]minVelocityItersNumber of velocity iterations the solver should perform for this body. Range: [1,255]
See Also
getSolverIterationCounts()
virtual void PxRigidDynamic::setStabilizationThreshold ( PxReal  threshold)
pure virtual

Sets the mass-normalized kinetic energy threshold below which an actor may participate in stabilization.

Actors whose kinetic energy divided by their mass is above this threshold will not participate in stabilization.

This value has no effect if PxSceneFlag::eENABLE_STABILIZATION was not enabled on the PxSceneDesc.

Default: 1e-5f * PxTolerancesScale::speed * PxTolerancesScale::speed

Parameters
[in]thresholdEnergy below which an actor may participate in stabilization. Range: (0,inf]
See Also
getStabilizationThreshold() PxSceneFlag::eENABLE_STABILIZATION
virtual void PxRigidDynamic::setWakeCounter ( PxReal  wakeCounterValue)
pure virtual

Sets the wake counter for the actor.

The wake counter value determines the minimum amount of time until the body can be put to sleep. Please note that a body will not be put to sleep if the energy is above the specified threshold (see setSleepThreshold()) or if other awake bodies are touching it.

Note
Passing in a positive value will wake the actor up automatically.
It is invalid to use this method for kinematic actors since the wake counter for kinematics is defined based on whether a target pose has been set (see the comment in isSleeping()).
It is invalid to use this method if PxActorFlag::eDISABLE_SIMULATION is set.

Default: 0.4 (which corresponds to 20 frames for a time step of 0.02)

Parameters
[in]wakeCounterValueWake counter value. Range: [0, PX_MAX_F32)
See Also
isSleeping() getWakeCounter()
virtual void PxRigidDynamic::wakeUp ( )
pure virtual

Wakes up the actor if it is sleeping.

The actor will get woken up and might cause other touching actors to wake up as well during the next simulation step.

Note
This will set the wake counter of the actor to the value specified in PxSceneDesc::wakeCounterResetValue.
It is invalid to use this method if the actor has not been added to a scene already or if PxActorFlag::eDISABLE_SIMULATION is set.
It is invalid to use this method for kinematic actors since the sleep state for kinematics is defined based on whether a target pose has been set (see the comment in isSleeping()).
See Also
isSleeping() putToSleep()

The documentation for this class was generated from the following file:


Copyright © 2008-2015 NVIDIA Corporation, 2701 San Tomas Expressway, Santa Clara, CA 95050 U.S.A. All rights reserved. www.nvidia.com