- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class physx.NativeObject
NativeObject.Allocator<T> -
Field Summary
FieldsFields inherited from class physx.NativeObject
address, isExternallyAllocated, SIZEOF_BYTE, SIZEOF_DOUBLE, SIZEOF_FLOAT, SIZEOF_INT, SIZEOF_LONG, SIZEOF_POINTER, SIZEOF_SHORT -
Constructor Summary
ConstructorsModifierConstructorDescriptionConstructor to build an empty tetmesh descriptionprotectedPxTetrahedronMeshDesc(long address) PxTetrahedronMeshDesc(PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices) Constructor to build a tetmeshdescription that links to the vertices and indices providedPxTetrahedronMeshDesc(PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices, PxTetrahedronMeshFormatEnum meshFormat) Constructor to build a tetmeshdescription that links to the vertices and indices providedPxTetrahedronMeshDesc(PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices, PxTetrahedronMeshFormatEnum meshFormat, short numberOfTetsPerHexElement) Constructor to build a tetmeshdescription that links to the vertices and indices provided -
Method Summary
Modifier and TypeMethodDescriptionstatic PxTetrahedronMeshDescarrayGet(long baseAddress, int index) static PxTetrahedronMeshDesccreateAt(long address) static PxTetrahedronMeshDesccreateAt(long address, PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices) static PxTetrahedronMeshDesccreateAt(long address, PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices, PxTetrahedronMeshFormatEnum meshFormat) static PxTetrahedronMeshDesccreateAt(long address, PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices, PxTetrahedronMeshFormatEnum meshFormat, short numberOfTetsPerHexElement) static <T> PxTetrahedronMeshDesccreateAt(T allocator, NativeObject.Allocator<T> allocate) static <T> PxTetrahedronMeshDesccreateAt(T allocator, NativeObject.Allocator<T> allocate, PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices) static <T> PxTetrahedronMeshDesccreateAt(T allocator, NativeObject.Allocator<T> allocate, PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices, PxTetrahedronMeshFormatEnum meshFormat) static <T> PxTetrahedronMeshDesccreateAt(T allocator, NativeObject.Allocator<T> allocate, PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices, PxTetrahedronMeshFormatEnum meshFormat, short numberOfTetsPerHexElement) voiddestroy()getFlags()Flags bits, combined from values of the enum ::PxMeshFlagOptional pointer to first material index, or NULL.Pointer to first vertex point.Pointer to first tetrahedron.shortUsed for simulation meshes only.booleanisValid()voidsetFlags(PxMeshFlags value) Flags bits, combined from values of the enum ::PxMeshFlagvoidOptional pointer to first material index, or NULL.voidsetPoints(PxBoundedData value) Pointer to first vertex point.voidsetTetrahedrons(PxBoundedData value) Pointer to first tetrahedron.voidsetTetsPerElement(short value) Used for simulation meshes only.static PxTetrahedronMeshDescwrapPointer(long address) Methods inherited from class physx.NativeObject
checkNotNull, equals, getAddress, hashCode
-
Field Details
-
SIZEOF
public static final int SIZEOF -
ALIGNOF
public static final int ALIGNOF- See Also:
-
-
Constructor Details
-
PxTetrahedronMeshDesc
protected PxTetrahedronMeshDesc(long address) -
PxTetrahedronMeshDesc
public PxTetrahedronMeshDesc()Constructor to build an empty tetmesh description -
PxTetrahedronMeshDesc
Constructor to build a tetmeshdescription that links to the vertices and indices provided -
PxTetrahedronMeshDesc
public PxTetrahedronMeshDesc(PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices, PxTetrahedronMeshFormatEnum meshFormat) Constructor to build a tetmeshdescription that links to the vertices and indices provided -
PxTetrahedronMeshDesc
public PxTetrahedronMeshDesc(PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices, PxTetrahedronMeshFormatEnum meshFormat, short numberOfTetsPerHexElement) Constructor to build a tetmeshdescription that links to the vertices and indices provided
-
-
Method Details
-
wrapPointer
-
arrayGet
-
createAt
- Parameters:
address- Pre-allocated memory, where the object is created.- Returns:
- Stack allocated object of PxTetrahedronMeshDesc
-
createAt
- Type Parameters:
T- Allocator class, e.g. LWJGL's MemoryStack.- Parameters:
allocator- Object to use for allocation, e.g. an instance of LWJGL's MemoryStack.allocate- Method to call on allocator to obtain the target address, e.g. MemoryStack::nmalloc.- Returns:
- Stack allocated object of PxTetrahedronMeshDesc
-
createAt
public static PxTetrahedronMeshDesc createAt(long address, PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices) - Parameters:
address- Pre-allocated memory, where the object is created.meshVertices- WebIDL type:PxArray_PxVec3[Ref]meshTetIndices- WebIDL type:PxArray_PxU32[Ref]- Returns:
- Stack allocated object of PxTetrahedronMeshDesc
-
createAt
public static <T> PxTetrahedronMeshDesc createAt(T allocator, NativeObject.Allocator<T> allocate, PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices) - Type Parameters:
T- Allocator class, e.g. LWJGL's MemoryStack.- Parameters:
allocator- Object to use for allocation, e.g. an instance of LWJGL's MemoryStack.allocate- Method to call on allocator to obtain the target address, e.g. MemoryStack::nmalloc.meshVertices- WebIDL type:PxArray_PxVec3[Ref]meshTetIndices- WebIDL type:PxArray_PxU32[Ref]- Returns:
- Stack allocated object of PxTetrahedronMeshDesc
-
createAt
public static PxTetrahedronMeshDesc createAt(long address, PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices, PxTetrahedronMeshFormatEnum meshFormat) - Parameters:
address- Pre-allocated memory, where the object is created.meshVertices- WebIDL type:PxArray_PxVec3[Ref]meshTetIndices- WebIDL type:PxArray_PxU32[Ref]meshFormat- WebIDL type:PxTetrahedronMeshFormatEnum[enum]- Returns:
- Stack allocated object of PxTetrahedronMeshDesc
-
createAt
public static <T> PxTetrahedronMeshDesc createAt(T allocator, NativeObject.Allocator<T> allocate, PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices, PxTetrahedronMeshFormatEnum meshFormat) - Type Parameters:
T- Allocator class, e.g. LWJGL's MemoryStack.- Parameters:
allocator- Object to use for allocation, e.g. an instance of LWJGL's MemoryStack.allocate- Method to call on allocator to obtain the target address, e.g. MemoryStack::nmalloc.meshVertices- WebIDL type:PxArray_PxVec3[Ref]meshTetIndices- WebIDL type:PxArray_PxU32[Ref]meshFormat- WebIDL type:PxTetrahedronMeshFormatEnum[enum]- Returns:
- Stack allocated object of PxTetrahedronMeshDesc
-
createAt
public static PxTetrahedronMeshDesc createAt(long address, PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices, PxTetrahedronMeshFormatEnum meshFormat, short numberOfTetsPerHexElement) - Parameters:
address- Pre-allocated memory, where the object is created.meshVertices- WebIDL type:PxArray_PxVec3[Ref]meshTetIndices- WebIDL type:PxArray_PxU32[Ref]meshFormat- WebIDL type:PxTetrahedronMeshFormatEnum[enum]numberOfTetsPerHexElement- WebIDL type: unsigned short- Returns:
- Stack allocated object of PxTetrahedronMeshDesc
-
createAt
public static <T> PxTetrahedronMeshDesc createAt(T allocator, NativeObject.Allocator<T> allocate, PxArray_PxVec3 meshVertices, PxArray_PxU32 meshTetIndices, PxTetrahedronMeshFormatEnum meshFormat, short numberOfTetsPerHexElement) - Type Parameters:
T- Allocator class, e.g. LWJGL's MemoryStack.- Parameters:
allocator- Object to use for allocation, e.g. an instance of LWJGL's MemoryStack.allocate- Method to call on allocator to obtain the target address, e.g. MemoryStack::nmalloc.meshVertices- WebIDL type:PxArray_PxVec3[Ref]meshTetIndices- WebIDL type:PxArray_PxU32[Ref]meshFormat- WebIDL type:PxTetrahedronMeshFormatEnum[enum]numberOfTetsPerHexElement- WebIDL type: unsigned short- Returns:
- Stack allocated object of PxTetrahedronMeshDesc
-
destroy
public void destroy() -
getMaterialIndices
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
-
setMaterialIndices
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
-
getPoints
Pointer to first vertex point. -
setPoints
Pointer to first vertex point. -
getTetrahedrons
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.
-
setTetrahedrons
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.
-
getFlags
Flags bits, combined from values of the enum ::PxMeshFlag -
setFlags
Flags bits, combined from values of the enum ::PxMeshFlag -
getTetsPerElement
public short getTetsPerElement()Used for simulation meshes only. Defines if this tet mesh should be simulated as a tet mesh, or if a set of tetrahedra should be used to represent another shape, e.g. a hexahedral mesh constructed from 5 or 6 elements. -
setTetsPerElement
public void setTetsPerElement(short value) Used for simulation meshes only. Defines if this tet mesh should be simulated as a tet mesh, or if a set of tetrahedra should be used to represent another shape, e.g. a hexahedral mesh constructed from 5 or 6 elements. -
isValid
public boolean isValid()- Returns:
- WebIDL type: boolean
-