FMeshShapeGenerator

Base class for triangle mesh generators (eg like to generate sphere, cylinder, etc) Subclasses must implement [Generate()](API\Editor\DetailCustomizations\EPropertyEditorGuidActions__Type)

Windows
MacOS
Linux

Inheritance Hierarchy

References

Module

GeometricObjects

Header

/Engine/Plugins/Experimental/GeometryProcessing/Source/GeometricObjects/Public/Generators/MeshShapeGenerator.h

Include

#include "Generators/MeshShapeGenerator.h"

Syntax

class FMeshShapeGenerator

Remarks

Base class for triangle mesh generators (eg like to generate sphere, cylinder, etc) Subclasses must implement Generate()

Variables

Name Description

Public variable

bool

 

bReverseOrientation

If true, reverse orientation of created mesh

Public variable

TArray< int >

 

NormalParentVertex

Parent vertex index for each Normal. Same length as Normals array.

Public variable

TArray< FVector...

 

Normals

Array of Normals.

Public variable

TArray< FIndex3...

 

TriangleNormals

Array of triangle corner Normals, stored as tuples of indices into Normals array.

Public variable

TArray< int >

 

TrianglePolygonIDs

Array of per-triangle integer polygon IDs. Same length as Triangles array.

Public variable

TArray< FIndex3...

 

Triangles

Array of triangle corner positions, stored as tuples of indices into Vertices array

Public variable

TArray< FIndex3...

 

TriangleUVs

Array of triangle corner UVs, stored as tuples of indices into UVs array.

Public variable

TArray< int >

 

UVParentVertex

Parent vertex index for each UV. Same length as UVs array.

Public variable

TArray< FVector...

 

UVs

Array of UV positions.

Public variable

TArray< FVector...

 

Vertices

Array of vertex positions

Destructors

Name Description

Public function Virtual

~FMeshShapeGenerator()

Functions

Name Description

Public function

int

 

AppendNormal

(
    const FVector3f& Normal,
    int ParentVertex
)

Public function

int

 

AppendTriangle

(
    int A,
    int B,
    int C
)

Public function

int

 

AppendUV

(
    const FVector2f& UV,
    int ParentVertex
)

Public function

int

 

AppendVertex

(
    const FVector3d& Position
)

Append a new vertex at the given Position

Public function Static

FVector2f

 

BilinearInterp

(
    const FVector2f& v00,
    const FVector2f& v10,
    const FVector2f& v11,
    const FVector2f& v01,
    float tx,
    float ty
)

Public function Static

FVector2d

 

BilinearInterp

(
    const FVector2d& v00,
    const FVector2d& v10,
    const FVector2d& v11,
    const FVector2d& v01,
    double tx,
    double ty
)

Public function Static

FVector3d

 

BilinearInterp

(
    const FVector3d& v00,
    const FVector3d& v10,
    const FVector3d& v11,
    const FVector3d& v01,
    double tx,
    double ty
)

Public function

void

 

ExtendBufferSizes

(
    int AddVertices,
    int AddTriangles,
    int AddUVs,
    int AddNormals
)

Extends the various internal buffers to the correct sizes for the given additional element counts

Public function

FMeshShapeGe...

 

Generate()

Subclasses implement this to generate mesh

Public function Const

bool

 

HasAttributes()

Public function Static

FVector3i

 

LinearInterp

(
    const FVector3i& a,
    const FVector3i& b,
    double t
)

Public function

void

 

Reset()

Clear arrays so that Generate() can be run again

Public function

void

 

SetBufferSizes

(
    int NumVertices,
    int NumTriangles,
    int NumUVs,
    int NumNormals
)

Set the various internal buffers to the correct sizes for the given element counts

Public function

void

 

SetNormal

(
    int Index,
    const FVector3f& Normal,
    int ParentVertex
)

Set Normal at Index to given value with given ParentVertex

Public function

void

 

SetTriangle

(
    int Index,
    int A,
    int B,
    int C,
    bool bClockwiseOverride
)

Public function

void

 

SetTriangle

(
    int Index,
    const FIndex3i& Tri
)

Public function

void

 

SetTriangle

(
    int Index,
    int A,
    int B,
    int C
)

Public function

void

 

SetTriangleNormals

(
    int Index,
    int A,
    int B,
    int C
)

Public function

void

 

SetTriangleNormals

(
    int Index,
    int A,
    int B,
    int C,
    bool bClockwiseOverride
)

Public function

void

 

SetTriangleNormals

(
    int Index,
    const FIndex3i& Tri
)

Public function

void

 

SetTrianglePolygon

(
    int Index,
    int PolygonID
)

Public function

void

 

SetTriangleUVs

(
    int Index,
    const FIndex3i& Tri
)

Public function

void

 

SetTriangleUVs

(
    int Index,
    int A,
    int B,
    int C,
    bool bClockwiseOverride
)

Public function

void

 

SetTriangleUVs

(
    int Index,
    int A,
    int B,
    int C
)

Public function

void

 

SetTriangleWithMatchedUVNormal

(
    int Index,
    int A,
    int B,
    int C
)

Set triangle and UVs and normals with matching indices Convenience function for shapes with no uv or normal seams

Public function

void

 

SetUV

(
    int Index,
    const FVector2f& UV,
    int ParentVertex
)

Set UV at Index to given value with given ParentVertex

Public function

void

 

SetVertex

(
    int Index,
    const FVector3d& Position
)

Set vertex at Index to given Position

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss