RavEngine
Loading...
Searching...
No Matches
physx::ExtGpu::PxParticleClothBufferHelper Class Referenceabstract

Helper class to manage PxParticleClothDesc buffers used for communicating particle based cloths to PxParticleClothBuffer. More...

#include <PxParticleExt.h>

Inheritance diagram for physx::ExtGpu::PxParticleClothBufferHelper:
[legend]

Public Member Functions

virtual void release ()=0
 
virtual PxU32 getMaxCloths () const =0
 
virtual PxU32 getNumCloths () const =0
 
virtual PxU32 getMaxSprings () const =0
 
virtual PxU32 getNumSprings () const =0
 
virtual PxU32 getMaxTriangles () const =0
 
virtual PxU32 getNumTriangles () const =0
 
virtual PxU32 getMaxParticles () const =0
 
virtual PxU32 getNumParticles () const =0
 
virtual void addCloth (const PxParticleCloth &particleCloth, const PxU32 *triangles, const PxU32 numTriangles, const PxParticleSpring *springs, const PxU32 numSprings, const PxVec4 *restPositions, const PxU32 numParticles)=0
 Adds a PxParticleCloth to this PxParticleClothBufferHelper instance.
 
virtual void addCloth (const PxReal blendScale, const PxReal restVolume, const PxReal pressure, const PxU32 *triangles, const PxU32 numTriangles, const PxParticleSpring *springs, const PxU32 numSprings, const PxVec4 *restPositions, const PxU32 numParticles)=0
 Adds a cloth to this PxParticleClothBufferHelper instance.
 
virtual PxParticleClothDesc & getParticleClothDesc ()=0
 Returns a PxParticleClothDesc for this PxParticleClothBufferHelper instance to be used for spring partitioning.
 

Detailed Description

Helper class to manage PxParticleClothDesc buffers used for communicating particle based cloths to PxParticleClothBuffer.

Member Function Documentation

◆ addCloth() [1/2]

virtual void physx::ExtGpu::PxParticleClothBufferHelper::addCloth ( const PxParticleCloth &  particleCloth,
const PxU32 *  triangles,
const PxU32  numTriangles,
const PxParticleSpring *  springs,
const PxU32  numSprings,
const PxVec4 *  restPositions,
const PxU32  numParticles 
)
pure virtual

Adds a PxParticleCloth to this PxParticleClothBufferHelper instance.

Parameters
[in]particleClothThe PxParticleCloth to be added.
[in]trianglesA pointer to the triangles
[in]numTrianglesThe number of triangles
[in]springsA pointer to the springs
[in]numSpringsThe number of springs
[in]restPositionsA pointer to the particle rest positions
[in]numParticlesThe number of particles in this cloth
See also
PxParticleCloth PxParticleSpring

Implemented in physx::ExtGpu::ParticleClothBuffersImpl, and physx::ExtGpu::ParticleClothBuffersImpl.

◆ addCloth() [2/2]

virtual void physx::ExtGpu::PxParticleClothBufferHelper::addCloth ( const PxReal  blendScale,
const PxReal  restVolume,
const PxReal  pressure,
const PxU32 *  triangles,
const PxU32  numTriangles,
const PxParticleSpring *  springs,
const PxU32  numSprings,
const PxVec4 *  restPositions,
const PxU32  numParticles 
)
pure virtual

Adds a cloth to this PxParticleClothBufferHelper instance.

Adds a cloth to this PxParticleClothBufferHelper instance. With this method the relevant parameters for inflatable simulation (restVolume, pressure) can be set directly.

Parameters
[in]blendScaleThis should be 1.f / (numPartitions + 1) if the springs are partitioned by the user. Otherwise this will be set during spring partitioning.
[in]restVolumeThe rest volume of the inflatable
[in]pressureThe pressure of the inflatable. The target inflatable volume is defined as restVolume * pressure. Setting this to > 0.0 will enable inflatable simulation.
[in]trianglesA pointer to the triangles
[in]numTrianglesThe number of triangles
[in]springsA pointer to the springs
[in]numSpringsThe number of springs
[in]restPositionsA pointer to the particle rest positions
[in]numParticlesThe number of particles in this cloth
See also
PxParticleSpring

Implemented in physx::ExtGpu::ParticleClothBuffersImpl, and physx::ExtGpu::ParticleClothBuffersImpl.

◆ getMaxCloths()

virtual PxU32 physx::ExtGpu::PxParticleClothBufferHelper::getMaxCloths ( ) const
pure virtual
Returns
The maximum number of cloths this PxParticleClothBufferHelper can hold.

Implemented in physx::ExtGpu::ParticleClothBuffersImpl, and physx::ExtGpu::ParticleClothBuffersImpl.

◆ getMaxParticles()

virtual PxU32 physx::ExtGpu::PxParticleClothBufferHelper::getMaxParticles ( ) const
pure virtual
Returns
The maximum number of particles this PxParticleClothBufferHelper can hold.

Implemented in physx::ExtGpu::ParticleClothBuffersImpl, and physx::ExtGpu::ParticleClothBuffersImpl.

◆ getMaxSprings()

virtual PxU32 physx::ExtGpu::PxParticleClothBufferHelper::getMaxSprings ( ) const
pure virtual
Returns
The maximum number of springs this PxParticleClothBufferHelper can hold.

Implemented in physx::ExtGpu::ParticleClothBuffersImpl, and physx::ExtGpu::ParticleClothBuffersImpl.

◆ getMaxTriangles()

virtual PxU32 physx::ExtGpu::PxParticleClothBufferHelper::getMaxTriangles ( ) const
pure virtual
Returns
The maximum number of triangles this PxParticleClothBufferHelper can hold.

Implemented in physx::ExtGpu::ParticleClothBuffersImpl, and physx::ExtGpu::ParticleClothBuffersImpl.

◆ getNumCloths()

virtual PxU32 physx::ExtGpu::PxParticleClothBufferHelper::getNumCloths ( ) const
pure virtual
Returns
The current number of cloths in this PxParticleClothBufferHelper.

Implemented in physx::ExtGpu::ParticleClothBuffersImpl, and physx::ExtGpu::ParticleClothBuffersImpl.

◆ getNumParticles()

virtual PxU32 physx::ExtGpu::PxParticleClothBufferHelper::getNumParticles ( ) const
pure virtual
Returns
The current number of particles in this PxParticleClothBufferHelper.

Implemented in physx::ExtGpu::ParticleClothBuffersImpl, and physx::ExtGpu::ParticleClothBuffersImpl.

◆ getNumSprings()

virtual PxU32 physx::ExtGpu::PxParticleClothBufferHelper::getNumSprings ( ) const
pure virtual
Returns
The current number of springs in this PxParticleClothBufferHelper.

Implemented in physx::ExtGpu::ParticleClothBuffersImpl, and physx::ExtGpu::ParticleClothBuffersImpl.

◆ getNumTriangles()

virtual PxU32 physx::ExtGpu::PxParticleClothBufferHelper::getNumTriangles ( ) const
pure virtual
Returns
The current number of triangles in this PxParticleClothBufferHelper.

Implemented in physx::ExtGpu::ParticleClothBuffersImpl, and physx::ExtGpu::ParticleClothBuffersImpl.

◆ getParticleClothDesc()

virtual PxParticleClothDesc & physx::ExtGpu::PxParticleClothBufferHelper::getParticleClothDesc ( )
pure virtual

Returns a PxParticleClothDesc for this PxParticleClothBufferHelper instance to be used for spring partitioning.

Returns
the PxParticleClothDesc.
See also
PxCreateAndPopulateParticleClothBuffer, PxParticleClothPreProcessor::partitionSprings

Implemented in physx::ExtGpu::ParticleClothBuffersImpl, and physx::ExtGpu::ParticleClothBuffersImpl.


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