|
| virtual void | onBegin (PxGpuParticleSystem *gpuParticleSystem, PxReal dt, CUstream stream)=0 |
| | callback called when the particle solver begins.
|
| |
| virtual void | onSolve (PxGpuParticleSystem *gpuParticleSystem, PxReal dt, CUstream stream)=0 |
| | callback called during the iterative particle solve stage.
|
| |
| virtual void | onFinalize (PxGpuParticleSystem *gpuParticleSystem, PxReal dt, CUstream stream)=0 |
| | callback called after all solver iterations have completed.
|
| |
|
virtual | ~PxCustomParticleSystemSolverCallback () |
| | Destructor.
|
| |
◆ onBegin()
| virtual void physx::PxCustomParticleSystemSolverCallback::onBegin |
( |
PxGpuParticleSystem * |
gpuParticleSystem, |
|
|
PxReal |
dt, |
|
|
CUstream |
stream |
|
) |
| |
|
pure virtual |
callback called when the particle solver begins.
This is called once per frame. It occurs after external forces have been pre-integrated into the particle state. It is called prior to the particles being reordered by spatial hash index, so state can be accessed in the unsorted buffers only at this stage. This provides an opportunity to add custom forces and modifications to position or velocity.
- Parameters
-
| [in] | gpuParticleSystem | A pointer to the GPU particle system. This pointer points to a mirror of the particle system in device memory. |
| [in] | dt | The time-step. |
| [in] | stream | The CUDA stream currently being used by the particle system. Additional kernels should either be launched on this stream, or synchronization events should be used to avoid race conditions. |
◆ onFinalize()
| virtual void physx::PxCustomParticleSystemSolverCallback::onFinalize |
( |
PxGpuParticleSystem * |
gpuParticleSystem, |
|
|
PxReal |
dt, |
|
|
CUstream |
stream |
|
) |
| |
|
pure virtual |
callback called after all solver iterations have completed.
This callback will be called once per frame, after integration has completed.
- Parameters
-
| [in] | gpuParticleSystem | A pointer to the GPU particle system. This pointer points to a mirror of the particle system in device memory. |
| [in] | dt | The time-step. |
| [in] | stream | The CUDA stream currently being used by the particle system. Additional kernels should either be launched on this stream, or synchronization events should be used to avoid race conditions. |
◆ onSolve()
| virtual void physx::PxCustomParticleSystemSolverCallback::onSolve |
( |
PxGpuParticleSystem * |
gpuParticleSystem, |
|
|
PxReal |
dt, |
|
|
CUstream |
stream |
|
) |
| |
|
pure virtual |
callback called during the iterative particle solve stage.
This callback will potentially be called multiple times between onBegin and onFinalize.
- Parameters
-
| [in] | gpuParticleSystem | A pointer to the GPU particle system. This pointer points to a mirror of the particle system in device memory. |
| [in] | dt | The time-step. |
| [in] | stream | The CUDA stream currently being used by the particle system. Additional kernels should either be launched on this stream, or synchronization events should be used to avoid race conditions. |
The documentation for this class was generated from the following file: