Navigation
API > API/Plugins > API/Plugins/DynamicMesh
Transfer vertex colors from one mesh (source) to another (target).
| Name | FTransferVertexColorAttribute |
| Type | class |
| Header File | /Engine/Plugins/Runtime/GeometryProcessing/Source/DynamicMesh/Public/Operations/TransferDynamicMeshAttributes.h |
| Include Path | #include "Operations/TransferDynamicMeshAttributes.h" |
Syntax
class FTransferVertexColorAttribute
Constructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
FTransferVertexColorAttribute
(
const FDynamicMesh3* InSourceMesh, |
Assumes that the InSourceMesh has a primary colors attribute. | Operations/TransferDynamicMeshAttributes.h |
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual ~FTransferVertexColorAttribute() |
Operations/TransferDynamicMeshAttributes.h |
Enums
Public
| Name | Remarks |
|---|---|
| ETransferMethod |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| bHardEdges | bool | Creates vertex instances per triangle to be able to have per-face vertex colors. | Operations/TransferDynamicMeshAttributes.h | |
| BiasRatio | float | Ratio used to blend a vertex between its position and the center of the face (0 = vertex position, 1 = face centroid) | Operations/TransferDynamicMeshAttributes.h | |
| bUseIntrinsicLaplacian | bool | If true, will use the intrinsic Delaunay mesh to construct sparse Cotangent Laplacian matrix. | Operations/TransferDynamicMeshAttributes.h | |
| bUseParallel | bool | Enable/disable multi-threading. | Operations/TransferDynamicMeshAttributes.h | |
| ForceInpaint | TArray< float > | Optional mask where if ForceInpaint[VertexID] != 0 we want to force the colors for the vertex to be computed | Operations/TransferDynamicMeshAttributes.h | |
| LayeredMeshSupport | bool | If true, when the closest point doesn't pass the normal threshold test, will try again with a flipped normal. | Operations/TransferDynamicMeshAttributes.h | |
| MatchedVertices | TArray< bool > | Outputs MatchedVertices[VertexID] is set to true for a target mesh vertex ID with a match found, false otherwise. | Operations/TransferDynamicMeshAttributes.h | |
| NormalThreshold | double | Maximum angle (in radians) difference between target and source point normals to be considered a match. | Operations/TransferDynamicMeshAttributes.h | |
| NumSmoothingIterations | int32 | The number of optional post-processing smoothing iterations applied to the vertices without the match. | Operations/TransferDynamicMeshAttributes.h | |
| Progress | FProgressCancel * | Optional Inputs Set this to be able to cancel the running operation. | Operations/TransferDynamicMeshAttributes.h | |
| SearchRadius | double | Optional Inputs for ETransferMethod::Inpaint method Radius for searching the closest point. | Operations/TransferDynamicMeshAttributes.h | |
| SmoothingStrength | float | The strength of each post-processing smoothing iteration. | Operations/TransferDynamicMeshAttributes.h | |
| TargetToWorld | FTransformSRT3d | Transform applied to the input target mesh or target point before transfer. | Operations/TransferDynamicMeshAttributes.h | |
| TargetVerticesSubset | TArray< int32 > | Optional subset of target mesh vertices to transfer weights to. | Operations/TransferDynamicMeshAttributes.h | |
| TransferMethod | ETransferMethod | The transfer method to compute the bone weights. | Operations/TransferDynamicMeshAttributes.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual bool TransferColorsToMesh
(
FDynamicMesh3& InOutTargetMesh |
Transfer the colors from the source mesh to the given target mesh and store the result in the primary colors attribute. | Operations/TransferDynamicMeshAttributes.h | |
bool TransferColorToPoint
(
FVector4f& OutColor, |
Compute the color for a given point using the ETransferMethod::ClosestPointOnSurface algorithm. | Operations/TransferDynamicMeshAttributes.h | |
virtual EOperationValidationResult Validate() |
Operations/TransferDynamicMeshAttributes.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual bool Cancelled() |
Operations/TransferDynamicMeshAttributes.h | ||
bool FindClosestPointOnSourceSurface
(
const FVector3d& InPoint, |
Find the closest point on the surface of the source mesh and return the ID of the triangle containing it and its barycentric coordinates. | Operations/TransferDynamicMeshAttributes.h | |
int32 TransferUsingClosestPoint
(
FDynamicMesh3& InOutTargetMesh, |
Transfer the colors from the source mesh to the given target mesh using the closest point algorithm. | Operations/TransferDynamicMeshAttributes.h |