PxCookSoftBodyMesh
Defined in include/cooking/PxCooking.h
-
bool PxCookSoftBodyMesh(const physx::PxCookingParams ¶ms, const physx::PxTetrahedronMeshDesc &simulationMeshDesc, const physx::PxTetrahedronMeshDesc &collisionMeshDesc, const physx::PxSoftBodySimulationDataDesc &softbodyDataDesc, physx::PxOutputStream &stream)
Cooks a softbody mesh.
The results are written to the stream.
To create a softbody mesh object it is necessary to first ‘cook’ the mesh data into a form which allows the SDK to perform efficient collision detection and to store data used during the FEM calculations.
PxCookSoftBodyMesh() allows a mesh description to be cooked into a binary stream suitable for loading and performing collision detection at runtime.
See also
PxCookConvexMesh() PxPhysics.createTriangleMesh() PxTriangleMeshCookingResult::Enum
- Parameters
params – [in] The cooking parameters
simulationMeshDesc – [in] The tetrahedron mesh descriptor to read the simulation mesh from.
collisionMeshDesc – [in] The tetrahedron mesh descriptor to read the collision mesh from.
softbodyDataDesc – [in] The softbody data descriptor to read mapping information from.
stream – [in] User stream to output the cooked data.
- Returns
true on success