Navigation
API > API/Plugins > API/Plugins/DynamicMesh > API/Plugins/DynamicMesh/Sampling
References
| Module | DynamicMesh |
| Header | /Engine/Plugins/Runtime/GeometryProcessing/Source/DynamicMesh/Public/Sampling/MeshSurfaceSampler.h |
| Include | #include "Sampling/MeshSurfaceSampler.h" |
Syntax
class FMeshSurfaceUVSampler
Remarks
FMeshSurfaceUVSampler computes FMeshUVSampleInfo's on a given mesh at given UV-space positions, this info can then be used by an external function to compute some application-specific sample.
Note: This class is similar to TMeshSurfaceUVSampler (the "old" class) but provides a more convenient API. This class computes the sample info and that's it. The old class computes the sample info internally but also immediately forwards it to an application-specific sampling function which must be provided as a callback and hence has a fixed signature and requires that the sample type is passed as a template parameter. Also the old class is more awkward to use when sampling multiple things, see the documentation of TMeshSurfaceUVSampler for more details.
Variables
| Type | Name | Description | |
|---|---|---|---|
| bool | bUVMeshSpatialInitialized | ||
| const FDynamicMesh3 * | Mesh | ||
| EMeshSurfaceSamplerQueryType | QueryType | ||
| FDynamicMeshUVMesh | UVMeshAdapter | BV tree for finding triangle for a given UV. Not always initialized. | |
| TMeshAABBTree3< FDynamicMeshUVMesh > | UVMeshSpatial | ||
| const FDynamicMeshUVOverlay * | UVOverlay |
Destructors
| Type | Name | Description | |
|---|---|---|---|
Functions
| Type | Name | Description | |
|---|---|---|---|
| void | Initialize
(
const FDynamicMesh3* Mesh, |
Initialize the sampler. | |
| void | |||
| bool | QuerySampleInfo
(
const FVector2d& UV, |
Fill in the given SampleInfo for the given UV location. | |
| bool | QuerySampleInfo
(
int32 UVTriangleID, |
Fill in the given SampleInfo for the given UV location in the given UVTriangleID. |