PxCreateParticleClothCooker

Defined in include/extensions/PxParticleClothCooker.h

ExtGpu::PxParticleClothCooker *PxCreateParticleClothCooker(PxU32 vertexCount, physx::PxVec4 *inVertices, PxU32 triangleIndexCount, PxU32 *inTriangleIndices, PxU32 constraintTypeFlags = ExtGpu::PxParticleClothConstraint::eTYPE_ALL, PxVec3 verticalDirection = PxVec3(0.0f, 1.0f, 0.0f), PxReal bendingConstraintMaxAngle = 20.0f / 360.0f * PxTwoPi)

Creates a PxParticleClothCooker.

Parameters
  • vertexCount[in] The number of vertices of the particle cloth.

  • inVertices[in] The vertex positions of the particle cloth.

  • triangleIndexCount[in] The number of triangles of the cloth mesh.

  • inTriangleIndices[in] The triangle indices of the cloth mesh

  • constraintTypeFlags[in] The types of constraints to generate. See PxParticleClothConstraint.

  • verticalDirection[in] The vertical direction of the cloth mesh. This is needed to generate the correct horizontal and vertical constraints to model shear stiffness.

  • bendingConstraintMaxAngle[in] The maximum angle considered in the bending constraints.

Returns

A pointer to the new PxParticleClothCooker.