RavEngine
Loading...
Searching...
No Matches
physx::PxSDFDesc Class Reference

A structure describing signed distance field for mesh. More...

#include <PxSDFDesc.h>

Collaboration diagram for physx::PxSDFDesc:
[legend]

Public Member Functions

PX_INLINE PxSDFDesc ()
 Constructor.
 
PX_INLINE bool isValid () const
 Returns true if the descriptor is valid.
 

Public Attributes

PxBoundedData sdf
 Pointer to first sdf array element.
 
PxDim3 dims
 Dimensions of sdf.
 
PxVec3 meshLower
 The Lower bound of the original mesh.
 
PxReal spacing
 The spacing of each sdf voxel.
 
PxU32 subgridSize
 The number of cells in a sparse subgrid block (full block has subgridSize^3 cells and (subgridSize+1)^3 samples). If set to zero, this indicates that only a dense background grid SDF is used without sparse blocks.
 
PxSdfBitsPerSubgridPixel::Enum bitsPerSubgridPixel
 Enumeration that defines the number of bits per subgrid pixel (either 32, 16 or 8bits)
 
PxDim3 sdfSubgrids3DTexBlockDim
 Number of subgrid blocks in the 3d texture. The full texture dimension will be sdfSubgrids3DTexBlockDim*(subgridSize+1).
 
PxBoundedData sdfSubgrids
 The data to create the 3d texture containg the packed subgrid blocks. Stored as PxU8 to support multiple formats (8, 16 and 32 bits per pixel)
 
PxBoundedData sdfStartSlots
 Array with start indices into the subgrid texture for every subgrid block. 10bits for z coordinate, 10bits for y and 10bits for x. Encoding is as follows: slot = (z << 20) | (y << 10) | x.
 
PxReal subgridsMinSdfValue
 The minimum value over all subgrid blocks. Used if normalized textures are used which is the case for 8 and 16bit formats.
 
PxReal subgridsMaxSdfValue
 The maximum value over all subgrid blocks. Used if normalized textures are used which is the case for 8 and 16bit formats.
 
PxBounds3 sdfBounds
 The bounds of the sdf. If left unassigned (empty), the bounds of the mesh will be used.
 
PxReal narrowBandThicknessRelativeToSdfBoundsDiagonal
 Narrow band thickness as a fraction of the bounds diagonal length. Every subgrid block that overlaps with the narrow band around the mesh surface will be kept providing high resultion around the mesh surface. The valid range of this parameter is (0, 1). The higher the value, the more subgrids will get created, the more memory will be required.
 
PxU32 numThreadsForSdfConstruction
 The number of threads that are launched to compute the signed distance field.
 

Detailed Description

A structure describing signed distance field for mesh.

Member Function Documentation

◆ isValid()

PX_INLINE bool physx::PxSDFDesc::isValid ( ) const

Returns true if the descriptor is valid.

Returns
true if the current settings are valid

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