utility functions for use with PxRigidActor and subclasses More...
#include <PxRigidActorExt.h>
Static Public Member Functions | |
static PxShape * | createExclusiveShape (PxRigidActor &actor, const PxGeometry &geometry, PxMaterial *const *materials, PxU16 materialCount, PxShapeFlags shapeFlags=PxShapeFlag::eVISUALIZATION|PxShapeFlag::eSCENE_QUERY_SHAPE|PxShapeFlag::eSIMULATION_SHAPE) |
Creates a new shape with default properties and a list of materials and adds it to the list of shapes of this actor. More... | |
static PX_FORCE_INLINE PxShape * | createExclusiveShape (PxRigidActor &actor, 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... | |
static PxBounds3 * | getRigidActorShapeLocalBoundsList (const PxRigidActor &actor, PxU32 &numBounds) |
Gets a list of bounds based on shapes in rigid actor. This list can be used to cook/create bounding volume hierarchy though PxCooking API. More... | |
utility functions for use with PxRigidActor and subclasses
|
inlinestatic |
Creates a new shape with default properties and a list of materials and adds it to the list of shapes of this actor.
This is equivalent to the following
PxShape* shape(...) = PxGetPhysics().createShape(...); // reference count is 1 actor->attachShape(shape); // increments reference count shape->release(); // releases user reference, leaving reference count at 1
As a consequence, detachShape() will result in the release of the last reference, and the shape will be deleted.
Sleeping: Does NOT wake the actor up automatically.
[in] | actor | the actor to which to attach the shape |
[in] | geometry | the geometry of the shape |
[in] | materials | a pointer to an array of material pointers |
[in] | materialCount | the count of materials |
[in] | shapeFlags | optional PxShapeFlags |
References PxRigidActor::attachShape(), geometry, PxGetPhysics(), and PxShape::release().
|
inlinestatic |
Creates a new shape with default properties and a single material adds it to the list of shapes of this actor.
This is equivalent to the following
PxShape* shape(...) = PxGetPhysics().createShape(...); // reference count is 1 actor->attachShape(shape); // increments reference count shape->release(); // releases user reference, leaving reference count at 1
As a consequence, detachShape() will result in the release of the last reference, and the shape will be deleted.
Sleeping: Does NOT wake the actor up automatically.
[in] | actor | the actor to which to attach the shape |
[in] | geometry | the geometry of the shape |
[in] | material | the material for the shape |
[in] | shapeFlags | optional PxShapeFlags |
References geometry.
|
static |
Gets a list of bounds based on shapes in rigid actor. This list can be used to cook/create bounding volume hierarchy though PxCooking API.
[in] | actor | The actor from which the bounds list is retrieved. |
[out] | numBounds | Number of bounds in returned list. |