Navigation
API > API/Plugins > API/Plugins/ModelingComponents
UMeshElementsVisualizer is a subclass of UPreviewGeometry that displays mesh elements. Currently supports wireframe, boundary edges, UV seams, Normal seams and Color seams.
UMeshElementsVisualizer initializes an instance of UMeshElementsVisualizerProperties as its .Settings value, and will watch for changes in these properties.
Mesh is accessed via lambda callback provided by creator/client. See SetMeshAccessFunction() comments
| Name | UMeshElementsVisualizer |
| Type | class |
| Header File | /Engine/Plugins/Runtime/MeshModelingToolset/Source/ModelingComponents/Public/Drawing/MeshElementsVisualizer.h |
| Include Path | #include "Drawing/MeshElementsVisualizer.h" |
Syntax
UCLASS (MinimalAPI, Transient)
class UMeshElementsVisualizer : public UPreviewGeometry
Inheritance Hierarchy
- UObjectBase → UObjectBaseUtility → UObject → UPreviewGeometry → UMeshElementsVisualizer
Typedefs
| Name | Type | Remarks | Include Path |
|---|---|---|---|
| ProcessDynamicMeshFunc | TFunctionRef< void(const UE::Geometry::FDynamicMesh3 &Mesh)> | A reference to a function that can be called with a const FDynamicMesh3 to do some computation on it. | Drawing/MeshElementsVisualizer.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| Settings | TObjectPtr< UMeshElementsVisualizerProperties > | Visualization settings | Drawing/MeshElementsVisualizer.h | |
| WireframeComponent | TObjectPtr< UMeshWireframeComponent > | Mesh Wireframe component, draws wireframe, boundaries, UV seams, normal seams, color seams | Drawing/MeshElementsVisualizer.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void NotifyMeshChanged() |
Call if mesh provided by MeshAccessFunction has been modified, will cause a full recomputation of all rendering data structures. | Drawing/MeshElementsVisualizer.h | |
void OnTick
(
float DeltaTime |
Client must call this every frame for changes to .Settings to be reflected in rendered result. | Drawing/MeshElementsVisualizer.h | |
void SetMeshAccessFunction
(
TUniqueFunction< void(ProcessDynamicMeshFunc)>&& MeshAccessFunction |
UMeshElementsVisualizer needs access to a mesh to generate it's data structures. | Drawing/MeshElementsVisualizer.h |
Protected
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
void UpdateLineDepthBiasScale() |
Drawing/MeshElementsVisualizer.h | ||
void UpdateVisibility() |
Drawing/MeshElementsVisualizer.h |
Overridden from UPreviewGeometry
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual void OnCreated() |
Called at the end of CreateInWorld() to allow subclasses to add additional setup | Drawing/MeshElementsVisualizer.h |