|
RavEngine
|
Classes | |
| class | MaterialEvent |
| struct | StartWriteResult |
Public Types | |
| enum | MATERIAL_EVENT { MATERIAL_ADD , MATERIAL_UPDATE , MATERIAL_REMOVE } |
Public Member Functions | |
| virtual void | release () |
| Deletes the scene. | |
| virtual void | setFlag (PxSceneFlag::Enum flag, bool value) |
| Sets a scene flag. You can only set one flag at a time. | |
| virtual PxSceneFlags | getFlags () const |
| Get the scene flags. | |
| virtual void | setGravity (const PxVec3 &) |
| Sets a constant gravity for the entire scene. | |
| virtual PxVec3 | getGravity () const |
| Retrieves the current gravity setting. | |
| virtual void | setBounceThresholdVelocity (const PxReal t) |
| Set the bounce threshold velocity. Collision speeds below this threshold will not cause a bounce. | |
| virtual PxReal | getBounceThresholdVelocity () const |
| Return the bounce threshold velocity. | |
| virtual void | setMaxBiasCoefficient (const PxReal t) |
| Set the max bias coefficient. | |
| virtual PxReal | getMaxBiasCoefficient () const |
| Gets the max bias coefficient. | |
| virtual void | setFrictionOffsetThreshold (const PxReal t) |
| Set the friction offset threshold. | |
| virtual PxReal | getFrictionOffsetThreshold () const |
| Gets the friction offset threshold. | |
| virtual void | setFrictionCorrelationDistance (const PxReal t) |
| Set the friction correlation distance. | |
| virtual PxReal | getFrictionCorrelationDistance () const |
| Gets the friction correlation distance. | |
| virtual void | setLimits (const PxSceneLimits &limits) |
| Set new scene limits. | |
| virtual PxSceneLimits | getLimits () const |
| Get current scene limits. | |
| virtual bool | addActor (PxActor &actor, const PxBVH *bvh) |
| Adds an actor to this scene. | |
| virtual void | removeActor (PxActor &actor, bool wakeOnLostTouch) |
| Removes an actor from this scene. | |
| virtual PxU32 | getNbConstraints () const |
| Returns the number of constraint shaders in the scene. | |
| virtual PxU32 | getConstraints (PxConstraint **buffer, PxU32 bufferSize, PxU32 startIndex=0) const |
| Retrieve all the constraint shaders in the scene. | |
| virtual bool | addArticulation (PxArticulationReducedCoordinate &) |
| Adds an articulation to this scene. | |
| virtual void | removeArticulation (PxArticulationReducedCoordinate &, bool wakeOnLostTouch) |
| Removes an articulation from this scene. | |
| virtual PxU32 | getNbArticulations () const |
| Returns the number of articulations in the scene. | |
| virtual PxU32 | getArticulations (PxArticulationReducedCoordinate **userBuffer, PxU32 bufferSize, PxU32 startIndex=0) const |
| Retrieve all the articulations in the scene. | |
| virtual PxU32 | getNbSoftBodies () const |
| Retrieve the number of soft bodies in the scene. | |
| virtual PxU32 | getSoftBodies (PxSoftBody **userBuffer, PxU32 bufferSize, PxU32 startIndex=0) const |
| Retrieve an array of all the soft bodies in the scene. | |
| virtual PxU32 | getNbParticleSystems (PxParticleSolverType::Enum type) const |
| Retrieve the number of particle systems of the requested type in the scene. | |
| virtual PxU32 | getParticleSystems (PxParticleSolverType::Enum type, PxParticleSystem **userBuffer, PxU32 bufferSize, PxU32 startIndex=0) const |
| Retrieve an array of all the particle systems of the requested type in the scene. | |
| virtual PxU32 | getNbFEMCloths () const |
| Retrieve the number of FEM cloths in the scene. | |
| virtual PxU32 | getFEMCloths (PxFEMCloth **userBuffer, PxU32 bufferSize, PxU32 startIndex=0) const |
| Retrieve an array of all the FEM cloths in the scene. | |
| virtual PxU32 | getNbHairSystems () const |
| Retrieve the number of hair systems in the scene. | |
| virtual PxU32 | getHairSystems (PxHairSystem **userBuffer, PxU32 bufferSize, PxU32 startIndex=0) const |
| Retrieve an array of all the hair systems in the scene. | |
| virtual bool | addAggregate (PxAggregate &) |
| Adds an aggregate to this scene. | |
| virtual void | removeAggregate (PxAggregate &, bool wakeOnLostTouch) |
| Removes an aggregate from this scene. | |
| virtual PxU32 | getNbAggregates () const |
| Returns the number of aggregates in the scene. | |
| virtual PxU32 | getAggregates (PxAggregate **userBuffer, PxU32 bufferSize, PxU32 startIndex=0) const |
| Retrieve all the aggregates in the scene. | |
| virtual bool | addCollection (const PxCollection &collection) |
| Adds objects in the collection to this scene. | |
| virtual void | setDominanceGroupPair (PxDominanceGroup group1, PxDominanceGroup group2, const PxDominanceGroupPair &dominance) |
| Specifies the dominance behavior of contacts between two actors with two certain dominance groups. | |
| virtual PxDominanceGroupPair | getDominanceGroupPair (PxDominanceGroup group1, PxDominanceGroup group2) const |
| Samples the dominance matrix. | |
| virtual PxU32 | getNbActors (PxActorTypeFlags types) const |
| Retrieve the number of actors of certain types in the scene. For supported types, see PxActorTypeFlags. | |
| virtual PxU32 | getActors (PxActorTypeFlags types, PxActor **buffer, PxU32 bufferSize, PxU32 startIndex=0) const |
| Retrieve an array of all the actors of certain types in the scene. For supported types, see PxActorTypeFlags. | |
| virtual PxActor ** | getActiveActors (PxU32 &nbActorsOut) |
| Queries the PxScene for a list of the PxActors whose transforms have been updated during the previous simulation step. Only includes actors of type PxRigidDynamic and PxArticulationLink. | |
| virtual void | getSimulationStatistics (PxSimulationStatistics &s) const |
| Call this method to retrieve statistics for the current simulation step. | |
| virtual PxClientID | createClient () |
| Reserves a new client ID. | |
| virtual PxFrictionType::Enum | getFrictionType () const |
| Return the friction model. | |
| virtual void | setSimulationEventCallback (PxSimulationEventCallback *callback) |
| Sets a user notify object which receives special simulation events when they occur. | |
| virtual PxSimulationEventCallback * | getSimulationEventCallback () const |
| Retrieves the simulationEventCallback pointer set with setSimulationEventCallback(). | |
| virtual void | setContactModifyCallback (PxContactModifyCallback *callback) |
| Sets a user callback object, which receives callbacks on all contacts generated for specified actors. | |
| virtual PxContactModifyCallback * | getContactModifyCallback () const |
| Retrieves the PxContactModifyCallback pointer set with setContactModifyCallback(). | |
| virtual void | setCCDContactModifyCallback (PxCCDContactModifyCallback *callback) |
| Sets a user callback object, which receives callbacks on all CCD contacts generated for specified actors. | |
| virtual PxCCDContactModifyCallback * | getCCDContactModifyCallback () const |
| Retrieves the PxCCDContactModifyCallback pointer set with setContactModifyCallback(). | |
| virtual void | setBroadPhaseCallback (PxBroadPhaseCallback *callback) |
| Sets a broad-phase user callback object. | |
| virtual PxBroadPhaseCallback * | getBroadPhaseCallback () const |
| Retrieves the PxBroadPhaseCallback pointer set with setBroadPhaseCallback(). | |
| virtual void | setCCDMaxPasses (PxU32 ccdMaxPasses) |
| Sets the maximum number of CCD passes. | |
| virtual PxU32 | getCCDMaxPasses () const |
| Gets the maximum number of CCD passes. | |
| virtual void | setCCDMaxSeparation (const PxReal t) |
| Set the maximum CCD separation. | |
| virtual PxReal | getCCDMaxSeparation () const |
| Gets the maximum CCD separation. | |
| virtual void | setCCDThreshold (const PxReal t) |
| Set the CCD threshold. | |
| virtual PxReal | getCCDThreshold () const |
| Gets the CCD threshold. | |
| virtual void | setFilterShaderData (const void *data, PxU32 dataSize) |
| Sets the shared global filter data which will get passed into the filter shader. | |
| virtual const void * | getFilterShaderData () const |
| Gets the shared global filter data in use for this scene. | |
| virtual PxU32 | getFilterShaderDataSize () const |
| Gets the size of the shared global filter data (PxSceneDesc.filterShaderData) | |
| virtual PxSimulationFilterShader | getFilterShader () const |
| Gets the custom collision filter shader in use for this scene. | |
| virtual PxSimulationFilterCallback * | getFilterCallback () const |
| Gets the custom collision filter callback in use for this scene. | |
| virtual bool | resetFiltering (PxActor &actor) |
| Marks the object to reset interactions and re-run collision filters in the next simulation step. | |
| virtual bool | resetFiltering (PxRigidActor &actor, PxShape *const *shapes, PxU32 shapeCount) |
| Marks the object to reset interactions and re-run collision filters for specified shapes in the next simulation step. | |
| virtual PxPairFilteringMode::Enum | getKinematicKinematicFilteringMode () const |
| Gets the pair filtering mode for kinematic-kinematic pairs. | |
| virtual PxPairFilteringMode::Enum | getStaticKinematicFilteringMode () const |
| Gets the pair filtering mode for static-kinematic pairs. | |
| virtual PxPhysics & | getPhysics () |
| Call this method to retrieve the Physics SDK. | |
| virtual bool | simulate (PxReal elapsedTime, physx::PxBaseTask *completionTask, void *scratchBlock, PxU32 scratchBlockSize, bool controlSimulation) |
| Advances the simulation by an elapsedTime time. | |
| virtual bool | advance (physx::PxBaseTask *completionTask) |
| Performs dynamics phase of the simulation pipeline. | |
| virtual bool | collide (PxReal elapsedTime, physx::PxBaseTask *completionTask, void *scratchBlock, PxU32 scratchBlockSize, bool controlSimulation=true) |
| Performs collision detection for the scene over elapsedTime. | |
| virtual bool | checkResults (bool block) |
| This checks to see if the simulation run has completed. | |
| virtual bool | checkCollision (bool block) |
| virtual bool | fetchCollision (bool block) |
| virtual bool | fetchResults (bool block, PxU32 *errorState) |
| virtual bool | fetchResultsStart (const PxContactPairHeader *&contactPairs, PxU32 &nbContactPairs, bool block=false) |
| virtual void | processCallbacks (physx::PxBaseTask *continuation) |
| virtual void | fetchResultsFinish (PxU32 *errorState=0) |
| virtual void | flush (bool sendPendingReports) |
| virtual void | flushSimulation (bool sendPendingReports) |
| Clear internal buffers and free memory. | |
| virtual const PxRenderBuffer & | getRenderBuffer () |
| Retrieves the render buffer. | |
| virtual void | setSolverBatchSize (PxU32 solverBatchSize) |
| Sets the number of actors required to spawn a separate rigid body solver thread. | |
| virtual PxU32 | getSolverBatchSize (void) const |
| Retrieves the number of actors required to spawn a separate rigid body solver thread. | |
| virtual void | setSolverArticulationBatchSize (PxU32 solverBatchSize) |
| Sets the number of articulations required to spawn a separate rigid body solver thread. | |
| virtual PxU32 | getSolverArticulationBatchSize (void) const |
| Retrieves the number of articulations required to spawn a separate rigid body solver thread. | |
| virtual bool | setVisualizationParameter (PxVisualizationParameter::Enum param, PxReal value) |
| Function that lets you set debug visualization parameters. | |
| virtual PxReal | getVisualizationParameter (PxVisualizationParameter::Enum param) const |
| Function that lets you query debug visualization parameters. | |
| virtual void | setVisualizationCullingBox (const PxBounds3 &box) |
| Defines a box in world space to which visualization geometry will be (conservatively) culled. Use a non-empty culling box to enable the feature, and an empty culling box to disable it. | |
| virtual PxBounds3 | getVisualizationCullingBox () const |
| Retrieves the visualization culling box. | |
| virtual PxTaskManager * | getTaskManager () const |
| Get the task manager associated with this scene. | |
| void | checkBeginWrite () const |
| virtual PxCudaContextManager * | getCudaContextManager () |
| virtual void | setNbContactDataBlocks (PxU32 numBlocks) |
| set the cache blocks that can be used during simulate(). | |
| virtual PxU32 | getNbContactDataBlocksUsed () const |
| get the number of cache blocks currently used by the scene | |
| virtual PxU32 | getMaxNbContactDataBlocksUsed () const |
| get the maximum number of cache blocks used by the scene | |
| virtual PxU32 | getContactReportStreamBufferSize () const |
| Return the value of PxSceneDesc::contactReportStreamBufferSize that was set when creating the scene with PxPhysics::createScene. | |
| virtual PxU32 | getTimestamp () const |
| Retrieves the scene's internal timestamp, increased each time a simulation step is completed. | |
| virtual PxCpuDispatcher * | getCpuDispatcher () const |
| Return the cpu dispatcher that was set in PxSceneDesc::cpuDispatcher when creating the scene with PxPhysics::createScene. | |
| virtual PxCudaContextManager * | getCudaContextManager () const |
| Return the CUDA context manager that was set in PxSceneDesc::cudaContextManager when creating the scene with PxPhysics::createScene. | |
| virtual PxBroadPhaseType::Enum | getBroadPhaseType () const |
| Returns broad-phase type. | |
| virtual bool | getBroadPhaseCaps (PxBroadPhaseCaps &caps) const |
| Gets broad-phase caps. | |
| virtual PxU32 | getNbBroadPhaseRegions () const |
| Returns number of regions currently registered in the broad-phase. | |
| virtual PxU32 | getBroadPhaseRegions (PxBroadPhaseRegionInfo *userBuffer, PxU32 bufferSize, PxU32 startIndex=0) const |
| Gets broad-phase regions. | |
| virtual PxU32 | addBroadPhaseRegion (const PxBroadPhaseRegion ®ion, bool populateRegion) |
| Adds a new broad-phase region. | |
| virtual bool | removeBroadPhaseRegion (PxU32 handle) |
| Removes a new broad-phase region. | |
| virtual bool | addActors (PxActor *const *actors, PxU32 nbActors) |
| Adds actors to this scene. Only supports actors of type PxRigidStatic and PxRigidDynamic. | |
| virtual bool | addActors (const PxPruningStructure &prunerStructure) |
| Adds a pruning structure together with its actors to this scene. Only supports actors of type PxRigidStatic and PxRigidDynamic. | |
| virtual void | removeActors (PxActor *const *actors, PxU32 nbActors, bool wakeOnLostTouch) |
| Removes actors from this scene. Only supports actors of type PxRigidStatic and PxRigidDynamic. | |
| virtual void | lockRead (const char *file=NULL, PxU32 line=0) |
| Lock the scene for reading from the calling thread. | |
| virtual void | unlockRead () |
| Unlock the scene from reading. | |
| virtual void | lockWrite (const char *file=NULL, PxU32 line=0) |
| Lock the scene for writing from this thread. | |
| virtual void | unlockWrite () |
| Unlock the scene from writing. | |
| virtual PxReal | getWakeCounterResetValue () const |
| Returns the wake counter reset value. | |
| virtual void | shiftOrigin (const PxVec3 &shift) |
| Shift the scene origin by the specified vector. | |
| virtual PxPvdSceneClient * | getScenePvdClient () |
| Returns the Pvd client associated with the scene. | |
| virtual void | copyArticulationData (void *data, void *index, PxArticulationGpuDataType::Enum dataType, const PxU32 nbCopyArticulations, void *copyEvent) |
| Copy GPU articulation data from the internal GPU buffer to a user-provided device buffer. | |
| virtual void | applyArticulationData (void *data, void *index, PxArticulationGpuDataType::Enum dataType, const PxU32 nbUpdatedArticulations, void *waitEvent, void *signalEvent) |
| Apply GPU articulation data from a user-provided device buffer to the internal GPU buffer. | |
| virtual void | copyContactData (void *data, const PxU32 numContactPatches, void *numContactPairs, void *copyEvent) |
| Copy contact data from the internal GPU buffer to a user-provided device buffer. | |
| virtual void | copySoftBodyData (void **data, void *dataSizes, void *softBodyIndices, PxSoftBodyDataFlag::Enum flag, const PxU32 nbCopySoftBodies, const PxU32 maxSize, void *copyEvent) |
| Copy GPU softbody data from the internal GPU buffer to a user-provided device buffer. | |
| virtual void | applySoftBodyData (void **data, void *dataSizes, void *softBodyIndices, PxSoftBodyDataFlag::Enum flag, const PxU32 nbUpdatedSoftBodies, const PxU32 maxSize, void *applyEvent) |
| Apply user-provided data to the internal softbody system. | |
| virtual void | copyBodyData (PxGpuBodyData *data, PxGpuActorPair *index, const PxU32 nbCopyActors, void *copyEvent) |
| Copy GPU rigid body data from the internal GPU buffer to a user-provided device buffer. | |
| virtual void | applyActorData (void *data, PxGpuActorPair *index, PxActorCacheFlag::Enum flag, const PxU32 nbUpdatedActors, void *waitEvent, void *signalEvent) |
| Apply user-provided data to rigid body. | |
| virtual void | computeDenseJacobians (const PxIndexDataPair *indices, PxU32 nbIndices, void *computeEvent) |
| Compute dense Jacobian matrices for specified articulations on the GPU. | |
| virtual void | computeGeneralizedMassMatrices (const PxIndexDataPair *indices, PxU32 nbIndices, void *computeEvent) |
| Compute the joint-space inertia matrices that maps joint accelerations to joint forces: forces = M * accelerations on the GPU. | |
| virtual void | computeGeneralizedGravityForces (const PxIndexDataPair *indices, PxU32 nbIndices, void *computeEvent) |
| Computes the joint DOF forces required to counteract gravitational forces for the given articulation pose. | |
| virtual void | computeCoriolisAndCentrifugalForces (const PxIndexDataPair *indices, PxU32 nbIndices, void *computeEvent) |
| Computes the joint DOF forces required to counteract coriolis and centrifugal forces for the given articulation pose. | |
| virtual void | applyParticleBufferData (const PxU32 *indices, const PxGpuParticleBufferIndexPair *bufferIndexPairs, const PxParticleBufferFlags *flags, PxU32 nbUpdatedBuffers, void *waitEvent, void *signalEvent) |
| Apply user-provided data to particle buffers. | |
| virtual PxSolverType::Enum | getSolverType () const |
| Return the solver model. | |
| virtual PxsSimulationController * | getSimulationController () |
| virtual void | setActiveActors (PxActor **actors, PxU32 nbActors) |
| virtual PxActor ** | getFrozenActors (PxU32 &nbActorsOut) |
| virtual void | setFrozenActorFlag (const bool buildFrozenActors) |
| virtual void | forceSceneQueryRebuild () |
| virtual void | frameEnd () |
| virtual void | setDynamicTreeRebuildRateHint (PxU32 dynamicTreeRebuildRateHint) |
| Sets the rebuild rate of the dynamic tree pruning structures. | |
| virtual PxU32 | getDynamicTreeRebuildRateHint () const |
| Retrieves the rebuild rate of the dynamic tree pruning structures. | |
| virtual void | forceRebuildDynamicTree (PxU32 prunerIndex) |
| Forces dynamic trees to be immediately rebuilt. | |
| virtual void | setUpdateMode (PxSceneQueryUpdateMode::Enum updateMode) |
| Sets scene query update mode. | |
| virtual PxSceneQueryUpdateMode::Enum | getUpdateMode () const |
| Gets scene query update mode. | |
| virtual PxU32 | getStaticTimestamp () const |
| Retrieves the system's internal scene query timestamp, increased each time a change to the static scene query structure is performed. | |
| virtual void | flushUpdates () |
| Flushes any changes to the scene query representation. | |
| virtual bool | raycast (const PxVec3 &origin, const PxVec3 &unitDir, const PxReal distance, PxRaycastCallback &hitCall, PxHitFlags hitFlags, const PxQueryFilterData &filterData, PxQueryFilterCallback *filterCall, const PxQueryCache *cache, PxGeometryQueryFlags flags) const |
| Performs a raycast against objects in the scene, returns results in a PxRaycastBuffer object or via a custom user callback implementation inheriting from PxRaycastCallback. | |
| virtual bool | sweep (const PxGeometry &geometry, const PxTransform &pose, const PxVec3 &unitDir, const PxReal distance, PxSweepCallback &hitCall, PxHitFlags hitFlags, const PxQueryFilterData &filterData, PxQueryFilterCallback *filterCall, const PxQueryCache *cache, const PxReal inflation, PxGeometryQueryFlags flags) const |
| Performs a sweep test against objects in the scene, returns results in a PxSweepBuffer object or via a custom user callback implementation inheriting from PxSweepCallback. | |
| virtual bool | overlap (const PxGeometry &geometry, const PxTransform &transform, PxOverlapCallback &hitCall, const PxQueryFilterData &filterData, PxQueryFilterCallback *filterCall, const PxQueryCache *cache, PxGeometryQueryFlags flags) const |
| Performs an overlap test of a given geometry against objects in the scene, returns results in a PxOverlapBuffer object or via a custom user callback implementation inheriting from PxOverlapCallback. | |
| virtual PxPruningStructureType::Enum | getStaticStructure () const |
| Return the value of PxSceneQueryDesc::staticStructure that was set when creating the scene with PxPhysics::createScene. | |
| virtual PxPruningStructureType::Enum | getDynamicStructure () const |
| Return the value of PxSceneQueryDesc::dynamicStructure that was set when creating the scene with PxPhysics::createScene. | |
| virtual void | sceneQueriesUpdate (physx::PxBaseTask *completionTask, bool controlSimulation) |
| Executes scene queries update tasks. | |
| virtual bool | checkQueries (bool block) |
| This checks to see if the scene queries update has completed. | |
| virtual bool | fetchQueries (bool block) |
| NpScene (const PxSceneDesc &desc, NpPhysics &) | |
| PX_FORCE_INLINE NpSceneQueries & | getNpSQ () |
| PX_FORCE_INLINE const NpSceneQueries & | getNpSQ () const |
| PX_FORCE_INLINE PxSceneQuerySystem & | getSQAPI () |
| PX_FORCE_INLINE const PxSceneQuerySystem & | getSQAPI () const |
| PX_FORCE_INLINE PxU64 | getContextId () const |
| PX_FORCE_INLINE PxTaskManager * | getTaskManagerFast () const |
| PX_FORCE_INLINE Sc::SimulationStage::Enum | getSimulationStage () const |
| PX_FORCE_INLINE void | setSimulationStage (Sc::SimulationStage::Enum stage) |
| bool | addActorInternal (PxActor &actor, const PxBVH *bvh) |
| void | removeActorInternal (PxActor &actor, bool wakeOnLostTouch, bool removeFromAggregate) |
| bool | addActorsInternal (PxActor *const *PX_RESTRICT actors, PxU32 nbActors, const Sq::PruningStructure *ps=NULL) |
| bool | addArticulationInternal (PxArticulationReducedCoordinate &) |
| void | removeArticulationInternal (PxArticulationReducedCoordinate &, bool wakeOnLostTouch, bool removeFromAggregate) |
| void | addMaterial (const NpMaterial &mat) |
| void | updateMaterial (const NpMaterial &mat) |
| void | removeMaterial (const NpMaterial &mat) |
| void | executeScene (PxBaseTask *continuation) |
| void | executeCollide (PxBaseTask *continuation) |
| void | executeAdvance (PxBaseTask *continuation) |
| void | constraintBreakEventNotify (PxConstraint *const *constraints, PxU32 count) |
| bool | loadFromDesc (const PxSceneDesc &) |
| template<typename T > | |
| void | removeFromRigidActorList (T &) |
| void | removeFromRigidDynamicList (NpRigidDynamic &) |
| void | removeFromRigidStaticList (NpRigidStatic &) |
| PX_FORCE_INLINE void | removeFromArticulationList (PxArticulationReducedCoordinate &) |
| PX_FORCE_INLINE void | removeFromSoftBodyList (PxSoftBody &) |
| PX_FORCE_INLINE void | removeFromFEMClothList (PxFEMCloth &) |
| PX_FORCE_INLINE void | removeFromParticleSystemList (PxPBDParticleSystem &) |
| PX_FORCE_INLINE void | removeFromParticleSystemList (PxFLIPParticleSystem &) |
| PX_FORCE_INLINE void | removeFromParticleSystemList (PxMPMParticleSystem &) |
| PX_FORCE_INLINE void | removeFromParticleSystemList (PxCustomParticleSystem &) |
| PX_FORCE_INLINE void | removeFromHairSystemList (PxHairSystem &) |
| PX_FORCE_INLINE void | removeFromAggregateList (PxAggregate &) |
| void | addDirtyConstraint (NpConstraint *constraint) |
| void | addToConstraintList (PxConstraint &) |
| void | removeFromConstraintList (PxConstraint &) |
| void | addArticulationLink (NpArticulationLink &link) |
| void | addArticulationLinkBody (NpArticulationLink &link) |
| void | addArticulationLinkConstraint (NpArticulationLink &link) |
| void | removeArticulationLink (NpArticulationLink &link, bool wakeOnLostTouch) |
| void | addArticulationAttachment (NpArticulationAttachment &attachment) |
| void | removeArticulationAttachment (NpArticulationAttachment &attachment) |
| void | addArticulationTendonJoint (NpArticulationTendonJoint &joint) |
| void | removeArticulationTendonJoint (NpArticulationTendonJoint &joint) |
| void | removeArticulationTendons (PxArticulationReducedCoordinate &articulation) |
| void | removeArticulationSensors (PxArticulationReducedCoordinate &articulation) |
| StartWriteResult::Enum | startWrite (bool allowReentry) |
| void | stopWrite (bool allowReentry) |
| bool | startRead () const |
| void | stopRead () const |
| PxU32 | getReadWriteErrorCount () const |
| PX_FORCE_INLINE void | updatePhysXIndicator () |
| void | scAddAggregate (NpAggregate &) |
| void | scRemoveAggregate (NpAggregate &) |
| void | scSwitchRigidToNoSim (NpActor &) |
| void | scSwitchRigidFromNoSim (NpActor &) |
| PX_FORCE_INLINE bool | isAPIReadForbidden () const |
| PX_FORCE_INLINE void | setAPIReadToForbidden () |
| PX_FORCE_INLINE void | setAPIReadToAllowed () |
| PX_FORCE_INLINE bool | isCollisionPhaseActive () const |
| PX_FORCE_INLINE bool | isAPIWriteForbidden () const |
| PX_FORCE_INLINE void | setAPIWriteToForbidden () |
| PX_FORCE_INLINE void | setAPIWriteToAllowed () |
| PX_FORCE_INLINE const Sc::Scene & | getScScene () const |
| PX_FORCE_INLINE Sc::Scene & | getScScene () |
| PX_FORCE_INLINE PxU32 | getFlagsFast () const |
| PX_FORCE_INLINE PxReal | getWakeCounterResetValueInternal () const |
| void | scAddActor (NpRigidStatic &, bool noSim, PxBounds3 *uninflatedBounds, const Gu::BVH *bvh) |
| void | scRemoveActor (NpRigidStatic &, bool wakeOnLostTouch, bool noSim) |
| void | scAddActor (NpRigidDynamic &, bool noSim, PxBounds3 *uninflatedBounds, const Gu::BVH *bvh) |
| void | scRemoveActor (NpRigidDynamic &, bool wakeOnLostTouch, bool noSim) |
| void | scAddActor (NpArticulationLink &, bool noSim, PxBounds3 *uninflatedBounds, const Gu::BVH *bvh) |
| void | scRemoveActor (NpArticulationLink &, bool wakeOnLostTouch, bool noSim) |
| void | scAddArticulation (NpArticulationReducedCoordinate &) |
| void | scRemoveArticulation (NpArticulationReducedCoordinate &) |
| void | scAddArticulationJoint (NpArticulationJointReducedCoordinate &) |
| void | scRemoveArticulationJoint (NpArticulationJointReducedCoordinate &) |
| void | scAddArticulationSpatialTendon (NpArticulationSpatialTendon &) |
| void | scRemoveArticulationSpatialTendon (NpArticulationSpatialTendon &) |
| void | scAddArticulationFixedTendon (NpArticulationFixedTendon &) |
| void | scRemoveArticulationFixedTendon (NpArticulationFixedTendon &) |
| void | scAddArticulationSensor (NpArticulationSensor &) |
| void | scRemoveArticulationSensor (NpArticulationSensor &) |
| void | createInOmniPVD (const PxSceneDesc &desc) |
| PX_FORCE_INLINE void | updatePvdProperties () |
| void | updateConstants (const PxArray< NpConstraint * > &constraints) |
| virtual PxgDynamicsMemoryConfig | getGpuDynamicsConfig () const |
| template<> | |
| PX_FORCE_INLINE void | removeFromRigidActorList (NpRigidDynamic &rigidDynamic) |
| template<> | |
| PX_FORCE_INLINE void | removeFromRigidActorList (NpRigidStatic &rigidStatic) |
Public Member Functions inherited from physx::PxScene | |
Public Member Functions inherited from physx::PxSceneSQSystem | |
| PX_FORCE_INLINE void | setSceneQueryUpdateMode (PxSceneQueryUpdateMode::Enum updateMode) |
| Sets scene query update mode. | |
| PX_FORCE_INLINE PxSceneQueryUpdateMode::Enum | getSceneQueryUpdateMode () const |
| Gets scene query update mode. | |
| PX_FORCE_INLINE PxU32 | getSceneQueryStaticTimestamp () const |
| Retrieves the scene's internal scene query timestamp, increased each time a change to the static scene query structure is performed. | |
| PX_FORCE_INLINE void | flushQueryUpdates () |
| Flushes any changes to the scene query representation. | |
| PX_FORCE_INLINE void | forceDynamicTreeRebuild (bool rebuildStaticStructure, bool rebuildDynamicStructure) |
| Forces dynamic trees to be immediately rebuilt. | |
Scene Query | |
Public Member Functions inherited from physx::PxUserAllocated | |
| PX_INLINE void * | operator new (size_t, void *address) |
| PX_INLINE void | operator delete (void *, void *) |
| template<typename Alloc > | |
| PX_INLINE void * | operator new (size_t size, Alloc alloc, const char *fileName, int line) |
| template<typename Alloc > | |
| PX_INLINE void * | operator new (size_t size, size_t, Alloc alloc, const char *fileName, int line) |
| template<typename Alloc > | |
| PX_INLINE void * | operator new[] (size_t size, Alloc alloc, const char *fileName, int line) |
| template<typename Alloc > | |
| PX_INLINE void * | operator new[] (size_t size, size_t, Alloc alloc, const char *fileName, int line) |
| template<typename Alloc > | |
| PX_INLINE void | operator delete (void *ptr, Alloc alloc, const char *fileName, int line) |
| template<typename Alloc > | |
| PX_INLINE void | operator delete[] (void *ptr, Alloc alloc, const char *fileName, int line) |
| PX_INLINE void | operator delete (void *ptr) |
| PX_INLINE void | operator delete[] (void *ptr) |
Public Attributes | |
| Cm::IDPool | mRigidActorIndexPool |
Public Attributes inherited from physx::PxScene | |
| void * | userData |
| user can assign this to whatever, usually to create a 1:1 relationship with a user object. | |
Additional Inherited Members | |
Protected Member Functions inherited from physx::PxScene |
Adds an actor to this scene.
| [in] | actor | Actor to add to scene. |
| [in] | bvh | BVH for actor shapes. |
Implements physx::PxScene.
|
virtual |
Adds a pruning structure together with its actors to this scene. Only supports actors of type PxRigidStatic and PxRigidDynamic.
| [in] | pruningStructure | Pruning structure for a set of actors. |
Implements physx::PxScene.
|
virtual |
Adds actors to this scene. Only supports actors of type PxRigidStatic and PxRigidDynamic.
| [in] | actors | Array of actors to add to scene. |
| [in] | nbActors | Number of actors in the array. |
Implements physx::PxScene.
|
virtual |
Adds an aggregate to this scene.
| [in] | aggregate | Aggregate to add to scene. |
Implements physx::PxScene.
|
virtual |
Adds an articulation to this scene.
| [in] | articulation | The articulation to add to the scene. |
Implements physx::PxScene.
|
virtual |
Adds a new broad-phase region.
The bounds for the new region must be non-empty, otherwise an error occurs and the call is ignored.
Note that by default, objects already existing in the SDK that might touch this region will not be automatically added to the region. In other words the newly created region will be empty, and will only be populated with new objects when they are added to the simulation, or with already existing objects when they are updated.
It is nonetheless possible to override this default behavior and let the SDK populate the new region automatically with already existing objects overlapping the incoming region. This has a cost though, and it should only be used when the game can not guarantee that all objects within the new region will be added to the simulation after the region itself.
Objects automatically move from one region to another during their lifetime. The system keeps tracks of what regions a given object is in. It is legal for an object to be in an arbitrary number of regions. However if an object leaves all regions, or is created outside of all regions, several things happen:
If an object goes out-of-bounds and user deletes it during the same frame, neither the out-of-bounds event nor the error message is generated.
| [in] | region | User-provided region data |
| [in] | populateRegion | Automatically populate new region with already existing objects overlapping it |
Implements physx::PxScene.
|
virtual |
Adds objects in the collection to this scene.
This function adds the following types of objects to this scene: PxRigidActor (except PxArticulationLink), PxAggregate, PxArticulationReducedCoordinate. This method is typically used after deserializing the collection in order to populate the scene with deserialized objects.
| [in] | collection | Objects to add to this scene. See #PxCollection |
Implements physx::PxScene.
|
virtual |
Performs dynamics phase of the simulation pipeline.
| [in] | completionTask | if non-NULL, this task will have its refcount incremented in advance(), then decremented when the scene is ready to have fetchResults called. So the task will not run until the application also calls removeReference(). |
Implements physx::PxScene.
|
virtual |
Apply user-provided data to rigid body.
| [in] | data | User-provided gpu data buffer which should be sized appropriately for the particular data that is requested. Further details provided in the user guide. |
| [in] | index | User provided PxGpuActorPair buffer. This buffer stores pairs of indices: the PxNodeIndex corresponding to the rigid body and an index corresponding to the location in the user buffer that this value should be placed. |
| [in] | flag | Flag defining which data the user wants to write to the rigid body |
| [in] | nbUpdatedActors | The number of updated rigid body |
| [in] | waitEvent | User-provided event for the rigid body stream to wait for data |
| [in] | signalEvent | User-provided event for the rigid body stream to signal when the read from the user buffer has completed |
Implements physx::PxScene.
|
virtual |
Apply GPU articulation data from a user-provided device buffer to the internal GPU buffer.
| [in] | data | User-provided gpu data buffer which should be sized appropriately for the particular data that is requested. Further details provided in the user guide. |
| [in] | index | User-provided gpu index buffer. This buffer stores the articulation indices which the user wants to write to. |
| [in] | dataType | Enum specifying the type of data the user wants to write to the articulations. |
| [in] | nbUpdatedArticulations | Number of articulations that data should be written to. |
| [in] | waitEvent | User-provided event for the articulation stream to wait for data. |
| [in] | signalEvent | User-provided event for the articulation stream to signal when the data read from the user buffer has completed. |
Implements physx::PxScene.
|
virtual |
Apply user-provided data to particle buffers.
This function should be used if the particle buffer flags are already on the device. Otherwise, use PxParticleBuffer::raiseFlags() from the CPU.
This assumes the data has been changed directly in the PxParticleBuffer.
| [in] | indices | User-provided index buffer that indexes into the BufferIndexPair and flags list. |
| [in] | bufferIndexPair | User-provided index pair buffer specifying the unique id and GPU particle system for each PxParticleBuffer. See PxGpuParticleBufferIndexPair. |
| [in] | flags | Flags to mark what data needs to be updated. See PxParticleBufferFlags. |
| [in] | nbUpdatedBuffers | The number of particle buffers to update. |
| [in] | waitEvent | User-provided event for the particle stream to wait for data. |
| [in] | signalEvent | User-provided event for the particle stream to signal when the data read from the user buffer has completed. |
Implements physx::PxScene.
|
virtual |
Apply user-provided data to the internal softbody system.
| [in] | data | User-provided gpu buffer containing a pointer to another gpu buffer for every softbody to process |
| [in] | dataSizes | The size of every buffer in bytes |
| [in] | softBodyIndices | User provided gpu index buffer. This buffer stores the updated softbody index. |
| [in] | flag | Flag defining which data the user wants to write to the softbody system |
| [in] | maxSize | The largest size stored in dataSizes. Used internally to decide how many threads to launch for the copy process. |
| [in] | nbUpdatedSoftBodies | The number of updated softbodies |
| [in] | applyEvent | User-provided event for the softbody stream to wait for data |
Implements physx::PxScene.
|
virtual |
This checks to see if the scene queries update has completed.
This does not cause the data available for reading to be updated with the results of the scene queries update, it is simply a status check. The bool will allow it to either return immediately or block waiting for the condition to be met so that it can return true
| [in] | block | When set to true will block until the condition is met. |
Implements physx::PxSceneSQSystem.
|
virtual |
This checks to see if the simulation run has completed.
This does not cause the data available for reading to be updated with the results of the simulation, it is simply a status check. The bool will allow it to either return immediately or block waiting for the condition to be met so that it can return true
| [in] | block | When set to true will block until the condition is met. |
Implements physx::PxScene.
|
virtual |
Performs collision detection for the scene over elapsedTime.
| [in] | elapsedTime | Amount of time to advance simulation by. The parameter has to be larger than 0, else the resulting behavior will be undefined. Range: (0, PX_MAX_F32) |
| [in] | completionTask | if non-NULL, this task will have its refcount incremented in collide(), then decremented when the scene is ready to have fetchResults called. So the task will not run until the application also calls removeReference(). |
| [in] | scratchMemBlock | a memory region for physx to use for temporary data during simulation. This block may be reused by the application after fetchResults returns. Must be aligned on a 16-byte boundary |
| [in] | scratchMemBlockSize | the size of the scratch memory block. Must be a multiple of 16K. |
| [in] | controlSimulation | if true, the scene controls its PxTaskManager simulation state. Leave true unless the application is calling the PxTaskManager start/stopSimulation() methods itself. |
Implements physx::PxScene.
|
virtual |
Computes the joint DOF forces required to counteract coriolis and centrifugal forces for the given articulation pose.
The size of the result can vary by articulation, since it depends on the number of links and degrees-of-freedom.
The size is determined using this formula: sizeof(float) * dofCount
The user must ensure that adequate space is provided for each articulation.
| [in] | indices | User-provided gpu buffer of (index, data) pairs. The entries map a GPU articulation index to a GPU block of memory where the returned matrix will be stored. |
| [in] | nbIndices | The number of (index, data) pairs provided. |
| [in] | computeEvent | User-provided event for the user to sync data. |
Implements physx::PxScene.
|
virtual |
Compute dense Jacobian matrices for specified articulations on the GPU.
The size of Jacobians can vary by articulation, since it depends on the number of links, degrees-of-freedom, and whether the base is fixed.
The size is determined using these formulas: nCols = (fixedBase ? 0 : 6) + dofCount nRows = (fixedBase ? 0 : 6) + (linkCount - 1) * 6;
The user must ensure that adequate space is provided for each Jacobian matrix.
| [in] | indices | User-provided gpu buffer of (index, data) pairs. The entries map a GPU articulation index to a GPU block of memory where the returned Jacobian will be stored. |
| [in] | nbIndices | The number of (index, data) pairs provided. |
| [in] | computeEvent | User-provided event for the user to sync data. |
Implements physx::PxScene.
|
virtual |
Computes the joint DOF forces required to counteract gravitational forces for the given articulation pose.
The size of the result can vary by articulation, since it depends on the number of links and degrees-of-freedom.
The size is determined using this formula: sizeof(float) * dofCount
The user must ensure that adequate space is provided for each articulation.
| [in] | indices | User-provided gpu buffer of (index, data) pairs. The entries map a GPU articulation index to a GPU block of memory where the returned matrix will be stored. |
| [in] | nbIndices | The number of (index, data) pairs provided. |
| [in] | computeEvent | User-provided event for the user to sync data. |
Implements physx::PxScene.
|
virtual |
Compute the joint-space inertia matrices that maps joint accelerations to joint forces: forces = M * accelerations on the GPU.
The size of matrices can vary by articulation, since it depends on the number of links and degrees-of-freedom.
The size is determined using this formula: sizeof(float) * dofCount * dofCount
The user must ensure that adequate space is provided for each mass matrix.
| [in] | indices | User-provided gpu buffer of (index, data) pairs. The entries map a GPU articulation index to a GPU block of memory where the returned matrix will be stored. |
| [in] | nbIndices | The number of (index, data) pairs provided. |
| [in] | computeEvent | User-provided event for the user to sync data. |
Implements physx::PxScene.
|
virtual |
Copy GPU articulation data from the internal GPU buffer to a user-provided device buffer.
| [in] | data | User-provided gpu data buffer which should be sized appropriately for the particular data that is requested. Further details provided in the user guide. |
| [in] | index | User-provided gpu index buffer. This buffer stores the articulation indices which the user wants to copy. |
| [in] | dataType | Enum specifying the type of data the user wants to read back from the articulations. |
| [in] | nbCopyArticulations | Number of articulations that data should be copied from. |
| [in] | copyEvent | User-provided event for the articulation stream to signal when the data copy to the user buffer has completed. |
Implements physx::PxScene.
|
virtual |
Copy GPU rigid body data from the internal GPU buffer to a user-provided device buffer.
| [in] | data | User-provided gpu data buffer which should nbCopyActors * sizeof(PxGpuBodyData). The only data it can copy is PxGpuBodyData. |
| [in] | index | User provided node PxGpuActorPair buffer. This buffer stores pairs of indices: the PxNodeIndex corresponding to the rigid body and an index corresponding to the location in the user buffer that this value should be placed. |
| [in] | nbCopyActors | The number of rigid body to be copied. |
| [in] | copyEvent | User-provided event for the user to sync data. |
Implements physx::PxScene.
|
virtual |
Copy contact data from the internal GPU buffer to a user-provided device buffer.
| [in] | data | User-provided gpu data buffer, which should be the size of PxGpuContactPair * numContactPairs |
| [in] | maxContactPairs | The maximum number of pairs that the buffer can contain |
| [in] | numContactPairs | The actual number of contact pairs that were written |
| [in] | copyEvent | User-provided event for the user to sync data |
Implements physx::PxScene.
|
virtual |
Copy GPU softbody data from the internal GPU buffer to a user-provided device buffer.
| [in] | data | User-provided gpu buffer containing a pointer to another gpu buffer for every softbody to process |
| [in] | dataSizes | The size of every buffer in bytes |
| [in] | softBodyIndices | User provided gpu index buffer. This buffer stores the softbody index which the user want to copy. |
| [in] | maxSize | The largest size stored in dataSizes. Used internally to decide how many threads to launch for the copy process. |
| [in] | flag | Flag defining which data the user wants to read back from the softbody system |
| [in] | nbCopySoftBodies | The number of softbodies to be copied. |
| [in] | copyEvent | User-provided event for the user to sync data |
Implements physx::PxScene.
|
virtual |
Reserves a new client ID.
PX_DEFAULT_CLIENT is always available as the default clientID. Additional clients are returned by this function. Clients cannot be released once created. An error is reported when more than a supported number of clients (currently 128) are created.
Implements physx::PxScene.
|
virtual |
This method must be called after collide() and before advance(). It will wait for the collision phase to finish. If the user makes an illegal simulation call, the SDK will issue an error message.
| [in] | block | When set to true will block until the condition is met, which is collision must finish running. |
Implements physx::PxScene.
|
virtual |
This method must be called after sceneQueriesUpdate. It will wait for the scene queries update to finish. If the user makes an illegal scene queries update call, the SDK will issue an error message.
If a new AABB tree build finished, then during fetchQueries the current tree within the pruning structure is swapped with the new tree.
| [in] | block | When set to true will block until the condition is met, which is tree built task must finish running. |
Implements physx::PxSceneSQSystem.
|
virtual |
This is the big brother to checkResults() it basically does the following:
| [in] | block | When set to true will block until results are available. |
| [out] | errorState | Used to retrieve hardware error codes. A non zero value indicates an error. |
Implements physx::PxScene.
|
virtual |
This call performs the second section of fetchResults.
It must be called after fetchResultsStart() returns and contact reports have been processed.
Note that once fetchResultsFinish() has been called, the contact streams returned in fetchResultsStart() will be invalid.
| [out] | errorState | Used to retrieve hardware error codes. A non zero value indicates an error. |
Implements physx::PxScene.
|
virtual |
This call performs the first section of fetchResults, and returns a pointer to the contact streams output by the simulation. It can be used to process contact pairs in parallel, which is often a limiting factor for fetchResults() performance.
After calling this function and processing the contact streams, call fetchResultsFinish(). Note that writes to the simulation are not permitted between the start of fetchResultsStart() and the end of fetchResultsFinish().
| [in] | block | When set to true will block until results are available. |
| [out] | contactPairs | an array of pointers to contact pair headers |
| [out] | nbContactPairs | the number of contact pairs |
Implements physx::PxScene.
|
virtual |
Clear internal buffers and free memory.
This method can be used to clear buffers and free internal memory without having to destroy the scene. Can be useful if the physics data gets streamed in and a checkpoint with a clean state should be created.
| [in] | sendPendingReports | When set to true pending reports will be sent out before the buffers get cleaned up (for instance lost touch contact/trigger reports due to deleted objects). |
!! TODO: Shrink all NpObject lists?
Implements physx::PxScene.
|
virtual |
Flushes any changes to the scene query representation.
This method updates the state of the scene query representation to match changes in the scene state.
By default, these changes are buffered until the next query is submitted. Calling this function will not change the results from scene queries, but can be used to ensure that a query will not perform update work in the course of its execution.
A thread performing updates will hold a write lock on the query structure, and thus stall other querying threads. In multithread scenarios it can be useful to explicitly schedule the period where this lock may be held for a significant period, so that subsequent queries issued from multiple threads will not block.
Implements physx::PxSceneQuerySystemBase.
|
virtual |
Forces dynamic trees to be immediately rebuilt.
| [in] | prunerIndex | Index of pruner containing the dynamic tree to rebuild |
Implements physx::PxSceneQuerySystemBase.
|
virtual |
Implements physx::NpSceneAccessor.
|
virtual |
Implements physx::NpSceneAccessor.
|
virtual |
Queries the PxScene for a list of the PxActors whose transforms have been updated during the previous simulation step. Only includes actors of type PxRigidDynamic and PxArticulationLink.
| [out] | nbActorsOut | The number of actors returned. |
Implements physx::PxScene.
|
virtual |
Retrieve an array of all the actors of certain types in the scene. For supported types, see PxActorTypeFlags.
| [in] | types | Combination of actor types to retrieve. |
| [out] | userBuffer | The buffer to receive actor pointers. |
| [in] | bufferSize | Size of provided user buffer. |
| [in] | startIndex | Index of first actor pointer to be retrieved |
Implements physx::PxScene.
|
virtual |
Retrieve all the aggregates in the scene.
| [out] | userBuffer | The buffer to receive aggregates pointers. |
| [in] | bufferSize | Size of provided user buffer. |
| [in] | startIndex | Index of first aggregate pointer to be retrieved |
Implements physx::PxScene.
|
virtual |
Retrieve all the articulations in the scene.
| [out] | userBuffer | The buffer to receive articulations pointers. |
| [in] | bufferSize | Size of provided user buffer. |
| [in] | startIndex | Index of first articulations pointer to be retrieved |
Implements physx::PxScene.
|
virtual |
Return the bounce threshold velocity.
Implements physx::PxScene.
|
virtual |
Retrieves the PxBroadPhaseCallback pointer set with setBroadPhaseCallback().
Implements physx::PxScene.
|
virtual |
Gets broad-phase caps.
| [out] | caps | Broad-phase caps |
Implements physx::PxScene.
|
virtual |
Gets broad-phase regions.
| [out] | userBuffer | Returned broad-phase regions |
| [in] | bufferSize | Size of userBuffer |
| [in] | startIndex | Index of first desired region, in [0 ; getNbRegions()[ |
Implements physx::PxScene.
|
virtual |
|
virtual |
Retrieves the PxCCDContactModifyCallback pointer set with setContactModifyCallback().
Implements physx::PxScene.
|
virtual |
Gets the maximum number of CCD passes.
Implements physx::PxScene.
|
virtual |
|
virtual |
|
virtual |
Retrieve all the constraint shaders in the scene.
| [out] | userBuffer | The buffer to receive constraint shader pointers. |
| [in] | bufferSize | Size of provided user buffer. |
| [in] | startIndex | Index of first constraint pointer to be retrieved |
Implements physx::PxScene.
|
virtual |
Retrieves the PxContactModifyCallback pointer set with setContactModifyCallback().
Implements physx::PxScene.
|
virtual |
Return the value of PxSceneDesc::contactReportStreamBufferSize that was set when creating the scene with PxPhysics::createScene.
Implements physx::PxScene.
|
virtual |
Return the cpu dispatcher that was set in PxSceneDesc::cpuDispatcher when creating the scene with PxPhysics::createScene.
Implements physx::PxScene.
|
virtual |
Return the CUDA context manager that was set in PxSceneDesc::cudaContextManager when creating the scene with PxPhysics::createScene.
Platform specific: Applies to PC GPU only.
Implements physx::PxScene.
|
virtual |
Samples the dominance matrix.
Implements physx::PxScene.
|
virtual |
Return the value of PxSceneQueryDesc::dynamicStructure that was set when creating the scene with PxPhysics::createScene.
Implements physx::PxSceneSQSystem.
|
virtual |
Retrieves the rebuild rate of the dynamic tree pruning structures.
Implements physx::PxSceneQuerySystemBase.
|
virtual |
Retrieve an array of all the FEM cloths in the scene.
| [out] | userBuffer | The buffer to write the FEM cloth pointers to |
| [in] | bufferSize | Size of the provided user buffer |
| [in] | startIndex | Index of first FEM cloth pointer to be retrieved |
Implements physx::PxScene.
|
virtual |
Gets the custom collision filter callback in use for this scene.
Implements physx::PxScene.
|
virtual |
Gets the custom collision filter shader in use for this scene.
Implements physx::PxScene.
|
virtual |
Gets the shared global filter data in use for this scene.
Implements physx::PxScene.
|
virtual |
Gets the size of the shared global filter data (PxSceneDesc.filterShaderData)
Implements physx::PxScene.
|
virtual |
Get the scene flags.
Implements physx::PxScene.
|
virtual |
Gets the friction correlation distance.
Implements physx::PxScene.
|
virtual |
Gets the friction offset threshold.
Implements physx::PxScene.
|
virtual |
Return the friction model.
Implements physx::PxScene.
|
virtual |
Implements physx::NpSceneAccessor.
|
inlinevirtual |
Implements physx::PxScene.
|
virtual |
Retrieves the current gravity setting.
Implements physx::PxScene.
|
virtual |
Retrieve an array of all the hair systems in the scene.
| [out] | userBuffer | The buffer to write the actor pointers to |
| [in] | bufferSize | Size of the provided user buffer |
| [in] | startIndex | Index of first actor pointer to be retrieved |
Implements physx::PxScene.
|
virtual |
Gets the pair filtering mode for kinematic-kinematic pairs.
Implements physx::PxScene.
|
virtual |
Get current scene limits.
Implements physx::PxScene.
|
virtual |
|
virtual |
get the maximum number of cache blocks used by the scene
This function may not be called while the scene is simulating
Implements physx::PxScene.
|
virtual |
Retrieve the number of actors of certain types in the scene. For supported types, see PxActorTypeFlags.
| [in] | types | Combination of actor types. |
Implements physx::PxScene.
|
virtual |
Returns the number of aggregates in the scene.
Implements physx::PxScene.
|
virtual |
Returns the number of articulations in the scene.
Implements physx::PxScene.
|
virtual |
Returns number of regions currently registered in the broad-phase.
Implements physx::PxScene.
|
virtual |
Returns the number of constraint shaders in the scene.
Implements physx::PxScene.
|
virtual |
get the number of cache blocks currently used by the scene
This function may not be called while the scene is simulating
Implements physx::PxScene.
|
virtual |
Retrieve the number of FEM cloths in the scene.
See getFEMCloths()
Implements physx::PxScene.
|
virtual |
Retrieve the number of hair systems in the scene.
Implements physx::PxScene.
|
virtual |
Retrieve the number of particle systems of the requested type in the scene.
| [in] | type | The particle system type. See PxParticleSolverType. Only one type can be requested per function call. |
See getParticleSystems(), PxParticleSolverType
Implements physx::PxScene.
|
virtual |
Retrieve the number of soft bodies in the scene.
Implements physx::PxScene.
|
virtual |
Retrieve an array of all the particle systems of the requested type in the scene.
| [in] | type | The particle system type. See PxParticleSolverType. Only one type can be requested per function call. |
| [out] | userBuffer | The buffer to receive particle system pointers. |
| [in] | bufferSize | Size of provided user buffer. |
| [in] | startIndex | Index of first particle system pointer to be retrieved |
See getNbParticleSystems(), PxParticleSolverType
Implements physx::PxScene.
|
virtual |
Call this method to retrieve the Physics SDK.
Implements physx::PxScene.
|
virtual |
Retrieves the render buffer.
This will contain the results of any active visualization for this scene.
Implements physx::PxScene.
|
virtual |
Returns the Pvd client associated with the scene.
Implements physx::PxScene.
|
virtual |
Implements physx::NpSceneAccessor.
|
virtual |
Retrieves the simulationEventCallback pointer set with setSimulationEventCallback().
Implements physx::PxScene.
|
virtual |
Call this method to retrieve statistics for the current simulation step.
| [out] | stats | Used to retrieve statistics for the current simulation step. |
Implements physx::PxScene.
|
virtual |
Retrieve an array of all the soft bodies in the scene.
| [out] | userBuffer | The buffer to receive actor pointers. |
| [in] | bufferSize | Size of provided user buffer. |
| [in] | startIndex | Index of first actor pointer to be retrieved |
Implements physx::PxScene.
|
virtual |
Retrieves the number of articulations required to spawn a separate rigid body solver thread.
Implements physx::PxScene.
|
virtual |
Retrieves the number of actors required to spawn a separate rigid body solver thread.
Implements physx::PxScene.
|
virtual |
|
virtual |
Gets the pair filtering mode for static-kinematic pairs.
Implements physx::PxScene.
|
virtual |
Return the value of PxSceneQueryDesc::staticStructure that was set when creating the scene with PxPhysics::createScene.
Implements physx::PxSceneSQSystem.
|
virtual |
Retrieves the system's internal scene query timestamp, increased each time a change to the static scene query structure is performed.
Implements physx::PxSceneQuerySystemBase.
|
inlinevirtual |
Get the task manager associated with this scene.
Implements physx::PxScene.
|
virtual |
Retrieves the scene's internal timestamp, increased each time a simulation step is completed.
Implements physx::PxScene.
|
virtual |
Gets scene query update mode.
Implements physx::PxSceneQuerySystemBase.
|
virtual |
Retrieves the visualization culling box.
Implements physx::PxScene.
|
virtual |
Function that lets you query debug visualization parameters.
| [in] | paramEnum | The Parameter to retrieve. |
Implements physx::PxScene.
|
virtual |
|
virtual |
Lock the scene for reading from the calling thread.
When the PxSceneFlag::eREQUIRE_RW_LOCK flag is enabled lockRead() must be called before any read calls are made on the scene.
Multiple threads may read at the same time, no threads may read while a thread is writing. If a call to lockRead() is made while another thread is holding a write lock then the calling thread will be blocked until the writing thread calls unlockWrite().
| file | String representing the calling file, for debug purposes |
| line | The source file line number, for debug purposes |
Implements physx::PxScene.
|
virtual |
Lock the scene for writing from this thread.
When the PxSceneFlag::eREQUIRE_RW_LOCK flag is enabled lockWrite() must be called before any write calls are made on the scene.
Only one thread may write at a time and no threads may read while a thread is writing. If a call to lockWrite() is made and there are other threads reading then the calling thread will be blocked until the readers complete.
Writers have priority. If a thread is blocked waiting to write then subsequent calls to lockRead() from other threads will be blocked until the writer completes.
| file | String representing the calling file, for debug purposes |
| line | The source file line number, for debug purposes |
Implements physx::PxScene.
|
virtual |
Performs an overlap test of a given geometry against objects in the scene, returns results in a PxOverlapBuffer object or via a custom user callback implementation inheriting from PxOverlapCallback.
| [in] | geometry | Geometry of object to check for overlap (supported types are: box, sphere, capsule, convex). |
| [in] | pose | Pose of the object. |
| [out] | hitCall | Overlap hit buffer or callback object used to report overlap hits. |
| [in] | filterData | Filtering data and simple logic. See #PxQueryFilterData #PxQueryFilterCallback |
| [in] | filterCall | Custom filtering logic (optional). Only used if the corresponding #PxQueryFlag flags are set. If NULL, all hits are assumed to overlap. |
| [in] | cache | Cached hit shape (optional). Overlap is performed against cached shape first. If no hit is found the overlap gets queried against the scene. |
| [in] | queryFlags | Optional flags controlling the query. Note: Filtering is not executed for a cached shape if supplied; instead, if a hit is found, it is assumed to be a blocking hit. Note: Using past touching hits as cache will produce incorrect behavior since the cached hit will always be treated as blocking. |
Implements physx::PxSceneQuerySystemBase.
|
virtual |
This call processes all event callbacks in parallel. It takes a continuation task, which will be executed once all callbacks have been processed.
This is a utility function to make it easier to process callbacks in parallel using the PhysX task system. It can only be used in conjunction with fetchResultsStart(...) and fetchResultsFinish(...)
| [in] | continuation | The task that will be executed once all callbacks have been processed. |
Implements physx::PxScene.
|
virtual |
Performs a raycast against objects in the scene, returns results in a PxRaycastBuffer object or via a custom user callback implementation inheriting from PxRaycastCallback.
| [in] | origin | Origin of the ray. |
| [in] | unitDir | Normalized direction of the ray. |
| [in] | distance | Length of the ray. Has to be in the [0, inf) range. |
| [out] | hitCall | Raycast hit buffer or callback object used to report raycast hits. |
| [in] | hitFlags | Specifies which properties per hit should be computed and returned via the hit callback. |
| [in] | filterData | Filtering data passed to the filter shader. |
| [in] | filterCall | Custom filtering logic (optional). Only used if the corresponding #PxQueryFlag flags are set. If NULL, all hits are assumed to be blocking. |
| [in] | cache | Cached hit shape (optional). Ray is tested against cached shape first. If no hit is found the ray gets queried against the scene. Note: Filtering is not executed for a cached shape if supplied; instead, if a hit is found, it is assumed to be a blocking hit. Note: Using past touching hits as cache will produce incorrect behavior since the cached hit will always be treated as blocking. |
| [in] | queryFlags | Optional flags controlling the query. |
Implements physx::PxSceneQuerySystemBase.
|
virtual |
Deletes the scene.
Removes any actors and constraint shaders from this scene (if the user hasn't already done so).
Be sure to not keep a reference to this object after calling release. Avoid release calls while the scene is simulating (in between simulate() and fetchResults() calls).
Implements physx::PxScene.
|
virtual |
Removes an actor from this scene.
| [in] | actor | Actor to remove from scene. |
| [in] | wakeOnLostTouch | Specifies whether touching objects from the previous frame should get woken up in the next frame. Only applies to PxArticulationReducedCoordinate and PxRigidActor types. |
Implements physx::PxScene.
|
virtual |
Removes actors from this scene. Only supports actors of type PxRigidStatic and PxRigidDynamic.
| [in] | actors | Array of actors to add to scene. |
| [in] | nbActors | Number of actors in the array. |
| [in] | wakeOnLostTouch | Specifies whether touching objects from the previous frame should get woken up in the next frame. Only applies to PxArticulationReducedCooridnate and PxRigidActor types. |
Implements physx::PxScene.
|
virtual |
Removes an aggregate from this scene.
| [in] | aggregate | Aggregate to remove from scene. |
| [in] | wakeOnLostTouch | Specifies whether touching objects from the previous frame should get woken up in the next frame. Only applies to PxArticulationReducedCoordinate and PxRigidActor types. |
Implements physx::PxScene.
|
virtual |
Removes an articulation from this scene.
| [in] | articulation | The articulation to remove from the scene. |
| [in] | wakeOnLostTouch | Specifies whether touching objects from the previous frame should get woken up in the next frame. Only applies to PxArticulationReducedCoordinate and PxRigidActor types. |
Implements physx::PxScene.
| void NpScene::removeArticulationInternal | ( | PxArticulationReducedCoordinate & | pxa, |
| bool | wakeOnLostTouch, | ||
| bool | removeFromAggregate | ||
| ) |
!!AL
|
virtual |
Removes a new broad-phase region.
If the region still contains objects, and if those objects do not overlap any region any more, they are not automatically removed from the simulation. Instead, the PxBroadPhaseCallback::onObjectOutOfBounds notification is used for each object. Users are responsible for removing the objects from the simulation if this is the desired behavior.
If the handle is invalid, or if a valid handle is removed twice, an error message is sent to the error stream.
| [in] | handle | Region's handle, as returned by PxScene::addBroadPhaseRegion. |
Implements physx::PxScene.
|
virtual |
Marks the object to reset interactions and re-run collision filters in the next simulation step.
This call forces the object to remove all existing collision interactions, to search anew for existing contact pairs and to run the collision filters again for found collision pairs.
Sleeping: Does wake up the actor.
| [in] | actor | The actor for which to re-evaluate interactions. |
Implements physx::PxScene.
|
virtual |
Marks the object to reset interactions and re-run collision filters for specified shapes in the next simulation step.
This is a specialization of the resetFiltering(PxActor& actor) method and allows to reset interactions for specific shapes of a PxRigidActor.
Sleeping: Does wake up the actor.
| [in] | actor | The actor for which to re-evaluate interactions. |
| [in] | shapes | The shapes for which to re-evaluate interactions. |
| [in] | shapeCount | Number of shapes in the list. |
Implements physx::PxScene.
|
virtual |
Executes scene queries update tasks.
This function will refit dirty shapes within the pruner and will execute a task to build a new AABB tree, which is build on a different thread. The new AABB tree is built based on the dynamic tree rebuild hint rate. Once the new tree is ready it will be commited in next fetchQueries call, which must be called after.
This function is equivalent to the following PxSceneQuerySystem calls: Synchronous calls:
This function is part of the PxSceneSQSystem interface because it uses the PxScene task system under the hood. But it calls PxSceneQuerySystem functions, which are independent from this system and could be called in a similar fashion by a separate, possibly user-defined task manager.
| [in] | completionTask | if non-NULL, this task will have its refcount incremented in sceneQueryUpdate(), then decremented when the scene is ready to have fetchQueries called. So the task will not run until the application also calls removeReference(). |
| [in] | controlSimulation | if true, the scene controls its PxTaskManager simulation state. Leave true unless the application is calling the PxTaskManager start/stopSimulation() methods itself. |
Implements physx::PxSceneSQSystem.
|
virtual |
Implements physx::NpSceneAccessor.
|
virtual |
Set the bounce threshold velocity. Collision speeds below this threshold will not cause a bounce.
Implements physx::PxScene.
|
virtual |
Sets a broad-phase user callback object.
| [in] | callback | Asynchronous broad-phase callback. See #PxBroadPhaseCallback. |
Implements physx::PxScene.
|
virtual |
Sets a user callback object, which receives callbacks on all CCD contacts generated for specified actors.
| [in] | callback | Asynchronous user contact modification callback. See #PxCCDContactModifyCallback. |
Implements physx::PxScene.
|
virtual |
Sets the maximum number of CCD passes.
| [in] | ccdMaxPasses | Maximum number of CCD passes |
Implements physx::PxScene.
|
virtual |
Set the maximum CCD separation.
Implements physx::PxScene.
|
virtual |
Set the CCD threshold.
Implements physx::PxScene.
|
virtual |
Sets a user callback object, which receives callbacks on all contacts generated for specified actors.
| [in] | callback | Asynchronous user contact modification callback. See #PxContactModifyCallback. |
Implements physx::PxScene.
|
virtual |
Specifies the dominance behavior of contacts between two actors with two certain dominance groups.
It is possible to assign each actor to a dominance groups using PxActor::setDominanceGroup().
With dominance groups one can have all contacts created between actors act in one direction only. This is useful, for example, if you want an object to push debris out of its way and be unaffected,while still responding physically to forces and collisions with non-debris objects.
Whenever a contact between two actors (a0, a1) needs to be solved, the groups (g0, g1) of both actors are retrieved. Then the PxDominanceGroupPair setting for this group pair is retrieved with getDominanceGroupPair(g0, g1).
In the contact, PxDominanceGroupPair::dominance0 becomes the dominance setting for a0, and PxDominanceGroupPair::dominance1 becomes the dominance setting for a1. A dominanceN setting of 1.0f, the default, will permit aN to be pushed or pulled by a(1-N) through the contact. A dominanceN setting of 0.0f, will however prevent aN to be pushed by a(1-N) via the contact. Thus, a PxDominanceGroupPair of (1.0f, 0.0f) makes the interaction one-way.
The matrix sampled by getDominanceGroupPair(g1, g2) is initialised by default such that:
if g1 == g2, then (1.0f, 1.0f) is returned if g1 < g2, then (0.0f, 1.0f) is returned if g1 > g2, then (1.0f, 0.0f) is returned
In other words, we permit actors in higher groups to be pushed around by actors in lower groups by default.
These settings should cover most applications, and in fact not overriding these settings may likely result in higher performance.
It is not possible to make the matrix asymetric, or to change the diagonal. In other words:
it is not possible to change (g1, g2) if (g1==g2) if you set
(g1, g2) to X, then (g2, g1) will implicitly and automatically be set to ~X, where:
~(1.0f, 1.0f) is (1.0f, 1.0f) ~(0.0f, 1.0f) is (1.0f, 0.0f) ~(1.0f, 0.0f) is (0.0f, 1.0f)
These two restrictions are to make sure that contacts between two actors will always evaluate to the same dominance setting, regardless of the order of the actors.
Dominance settings are currently specified as floats 0.0f or 1.0f because in the future we may permit arbitrary fractional settings to express 'partly-one-way' interactions.
Sleeping: Does NOT wake actors up automatically.
Implements physx::PxScene.
|
virtual |
Sets the rebuild rate of the dynamic tree pruning structures.
| [in] | dynamicTreeRebuildRateHint | Rebuild rate of the dynamic tree pruning structures. |
Implements physx::PxSceneQuerySystemBase.
|
virtual |
Sets the shared global filter data which will get passed into the filter shader.
| [in] | data | The shared global filter shader data. |
| [in] | dataSize | Size of the shared global filter shader data (in bytes). |
Implements physx::PxScene.
|
virtual |
Sets a scene flag. You can only set one flag at a time.
Implements physx::PxScene.
|
virtual |
Set the friction correlation distance.
Implements physx::PxScene.
|
virtual |
Set the friction offset threshold.
Implements physx::PxScene.
|
virtual |
Implements physx::NpSceneAccessor.
|
virtual |
Sets a constant gravity for the entire scene.
Sleeping: Does NOT wake the actor up automatically.
Implements physx::PxScene.
|
virtual |
Set new scene limits.
| [in] | limits | Scene limits. |
Implements physx::PxScene.
|
virtual |
Set the max bias coefficient.
Implements physx::PxScene.
|
virtual |
set the cache blocks that can be used during simulate().
Each frame the simulation requires memory to store contact, friction, and contact cache data. This memory is used in blocks of 16K. Each frame the blocks used by the previous frame are freed, and may be retrieved by the application using PxScene::flushSimulation()
This call will force allocation of cache blocks if the numBlocks parameter is greater than the currently allocated number of blocks, and less than the max16KContactDataBlocks parameter specified at scene creation time.
| [in] | numBlocks | The number of blocks to allocate. |
Implements physx::PxScene.
|
virtual |
Sets a user notify object which receives special simulation events when they occur.
| [in] | callback | User notification callback. See #PxSimulationEventCallback. |
Implements physx::PxScene.
|
virtual |
Sets the number of articulations required to spawn a separate rigid body solver thread.
| [in] | solverBatchSize | Number of articulations required to spawn a separate rigid body solver thread. |
Implements physx::PxScene.
|
virtual |
Sets the number of actors required to spawn a separate rigid body solver thread.
| [in] | solverBatchSize | Number of actors required to spawn a separate rigid body solver thread. |
Implements physx::PxScene.
|
virtual |
Sets scene query update mode.
| [in] | updateMode | Scene query update mode. |
Implements physx::PxSceneQuerySystemBase.
|
virtual |
Defines a box in world space to which visualization geometry will be (conservatively) culled. Use a non-empty culling box to enable the feature, and an empty culling box to disable it.
| [in] | box | the box to which the geometry will be culled. Empty box to disable the feature. |
Implements physx::PxScene.
|
virtual |
Function that lets you set debug visualization parameters.
Returns false if the value passed is out of range for usage specified by the enum.
| [in] | param | Parameter to set. See #PxVisualizationParameter |
| [in] | value | The value to set, see #PxVisualizationParameter for allowable values. Setting to zero disables visualization for the specified property, setting to a positive value usually enables visualization and defines the scale factor. |
Implements physx::PxScene.
|
virtual |
Shift the scene origin by the specified vector.
The poses of all objects in the scene and the corresponding data structures will get adjusted to reflect the new origin location (the shift vector will get subtracted from all object positions).
| [in] | shift | Translation vector to shift the origin by. |
Implements physx::PxScene.
|
virtual |
Advances the simulation by an elapsedTime time.
Calls to simulate() should pair with calls to fetchResults(): Each fetchResults() invocation corresponds to exactly one simulate() invocation; calling simulate() twice without an intervening fetchResults() or fetchResults() twice without an intervening simulate() causes an error condition.
scene->simulate(); ...do some processing until physics is computed... scene->fetchResults(); ...now results of run may be retrieved.
| [in] | elapsedTime | Amount of time to advance simulation by. The parameter has to be larger than 0, else the resulting behavior will be undefined. Range: (0, PX_MAX_F32) |
| [in] | completionTask | if non-NULL, this task will have its refcount incremented in simulate(), then decremented when the scene is ready to have fetchResults called. So the task will not run until the application also calls removeReference(). |
| [in] | scratchMemBlock | a memory region for physx to use for temporary data during simulation. This block may be reused by the application after fetchResults returns. Must be aligned on a 16-byte boundary |
| [in] | scratchMemBlockSize | the size of the scratch memory block. Must be a multiple of 16K. |
| [in] | controlSimulation | if true, the scene controls its PxTaskManager simulation state. Leave true unless the application is calling the PxTaskManager start/stopSimulation() methods itself. |
Implements physx::PxScene.
|
virtual |
Performs a sweep test against objects in the scene, returns results in a PxSweepBuffer object or via a custom user callback implementation inheriting from PxSweepCallback.
| [in] | geometry | Geometry of object to sweep (supported types are: box, sphere, capsule, convex). |
| [in] | pose | Pose of the sweep object. |
| [in] | unitDir | Normalized direction of the sweep. |
| [in] | distance | Sweep distance. Needs to be in [0, inf) range and >0 if eASSUME_NO_INITIAL_OVERLAP was specified. Will be clamped to PX_MAX_SWEEP_DISTANCE. |
| [out] | hitCall | Sweep hit buffer or callback object used to report sweep hits. |
| [in] | hitFlags | Specifies which properties per hit should be computed and returned via the hit callback. |
| [in] | filterData | Filtering data and simple logic. |
| [in] | filterCall | Custom filtering logic (optional). Only used if the corresponding #PxQueryFlag flags are set. If NULL, all hits are assumed to be blocking. |
| [in] | cache | Cached hit shape (optional). Sweep is performed against cached shape first. If no hit is found the sweep gets queried against the scene. Note: Filtering is not executed for a cached shape if supplied; instead, if a hit is found, it is assumed to be a blocking hit. Note: Using past touching hits as cache will produce incorrect behavior since the cached hit will always be treated as blocking. |
| [in] | inflation | This parameter creates a skin around the swept geometry which increases its extents for sweeping. The sweep will register a hit as soon as the skin touches a shape, and will return the corresponding distance and normal. Note: ePRECISE_SWEEP doesn't support inflation. Therefore the sweep will be performed with zero inflation. |
| [in] | queryFlags | Optional flags controlling the query. |
Implements physx::PxSceneQuerySystemBase.
|
virtual |
Unlock the scene from reading.
Implements physx::PxScene.
|
virtual |
Unlock the scene from writing.
Implements physx::PxScene.