PxTetrahedronMeshDesc
Defined in include/cooking/PxTetrahedronMeshDesc.h
-
class PxTetrahedronMeshDesc
Descriptor class for PxTetrahedronMesh (contains only pure geometric data).
See also
Public Types
Public Functions
-
inline PxTetrahedronMeshDesc()
Constructor to build an empty tetmesh description.
-
inline PxTetrahedronMeshDesc(physx::PxArray<physx::PxVec3> &meshVertices, physx::PxArray<physx::PxU32> &meshTetIndices, const PxTetrahedronMeshDesc::PxMeshFormat meshFormat = eTET_MESH, PxU16 numberOfTetsPerHexElement = 5)
Constructor to build a tetmeshdescription that links to the vertices and indices provided.
-
inline bool isValid() const
Public Members
-
PxTypedStridedData<PxFEMMaterialTableIndex> materialIndices
Optional pointer to first material index, or NULL.
There are PxTetrahedronMesh::numTriangles indices in total. Caller may add materialIndexStride bytes to the pointer to access the next triangle.
When a tetrahedron mesh collides with another object, a material is required at the collision point. If materialIndices is NULL, then the material of the PxShape instance is used. Otherwise, if the point of contact is on a tetrahedron with index i, then the material index is determined as: PxFEMMaterialTableIndex index = *(PxFEMMaterialTableIndex *)(((PxU8*)materialIndices) + materialIndexStride * i);
If the contact point falls on a vertex or an edge, a tetrahedron adjacent to the vertex or edge is selected, and its index used to look up a material. The selection is arbitrary but consistent over time.
Default: NULL
See also
materialIndexStride
-
PxBoundedData points
Pointer to first vertex point.
-
PxBoundedData tetrahedrons
Pointer to first tetrahedron.
Caller may add tetrhedronStrideBytes bytes to the pointer to access the next tetrahedron.
These are quadruplets of 0 based indices: vert0 vert1 vert2 vert3 vert0 vert1 vert2 vert3 vert0 vert1 vert2 vert3 …
where vertex is either a 32 or 16 bit unsigned integer. There are numTetrahedrons*4 indices.
This is declared as a void pointer because it is actually either an PxU16 or a PxU32 pointer.
-
PxMeshFlags flags
Flags bits, combined from values of the enum PxMeshFlag.
-
inline PxTetrahedronMeshDesc()