Navigation
API > API/Runtime > API/Runtime/GeometryCore
Base class for triangle mesh generators (eg like to generate sphere, cylinder, etc) Subclasses must implement Generate()
| Name | FMeshShapeGenerator |
| Type | class |
| Header File | /Engine/Source/Runtime/GeometryCore/Public/Generators/MeshShapeGenerator.h |
| Include Path | #include "Generators/MeshShapeGenerator.h" |
Syntax
class FMeshShapeGenerator
Derived Classes
FMeshShapeGenerator derived class hierarchy
Destructors
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
virtual ~FMeshShapeGenerator() |
Generators/MeshShapeGenerator.h |
Variables
Public
| Name | Type | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|---|
| bReverseOrientation | bool | If true, reverse orientation of created mesh | Generators/MeshShapeGenerator.h | |
| NormalParentVertex | TArray< int > | Parent vertex index for each Normal. Same length as Normals array. | Generators/MeshShapeGenerator.h | |
| Normals | TArray< FVector3f > | Array of Normals. | Generators/MeshShapeGenerator.h | |
| TriangleNormals | TArray< FIndex3i > | Array of triangle corner Normals, stored as tuples of indices into Normals array. | Generators/MeshShapeGenerator.h | |
| TrianglePolygonIDs | TArray< int > | Array of per-triangle integer polygon IDs. Same length as Triangles array. | Generators/MeshShapeGenerator.h | |
| Triangles | TArray< FIndex3i > | Array of triangle corner positions, stored as tuples of indices into Vertices array | Generators/MeshShapeGenerator.h | |
| TriangleUVs | TArray< FIndex3i > | Array of triangle corner UVs, stored as tuples of indices into UVs array. | Generators/MeshShapeGenerator.h | |
| UVParentVertex | TArray< int > | Parent vertex index for each UV. Same length as UVs array. | Generators/MeshShapeGenerator.h | |
| UVs | TArray< FVector2f > | Array of UV positions. | Generators/MeshShapeGenerator.h | |
| Vertices | TArray< FVector3d > | Array of vertex positions | Generators/MeshShapeGenerator.h |
Functions
Public
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
int AppendNormal
(
const FVector3f& Normal, |
Generators/MeshShapeGenerator.h | ||
int AppendTriangle
(
int A, |
Generators/MeshShapeGenerator.h | ||
int AppendUV
(
const FVector2f& UV, |
Generators/MeshShapeGenerator.h | ||
int AppendVertex
(
const FVector3d& Position |
Append a new vertex at the given Position | Generators/MeshShapeGenerator.h | |
void ExtendBufferSizes
(
int AddVertices, |
Extends the various internal buffers to the correct sizes for the given additional element counts | Generators/MeshShapeGenerator.h | |
FMeshShapeGenerator & Generate() |
Subclasses implement this to generate mesh | Generators/MeshShapeGenerator.h | |
bool HasAttributes() |
Generators/MeshShapeGenerator.h | ||
void Reset() |
Clear arrays so that Generate() can be run again | Generators/MeshShapeGenerator.h | |
void ResetAttributes
(
bool bResetPolygonIDs |
Reset UV and normal-related on a generator, leaving vertices and triangles alone | Generators/MeshShapeGenerator.h | |
void SetBufferSizes
(
int NumVertices, |
Set the various internal buffers to the correct sizes for the given element counts | Generators/MeshShapeGenerator.h | |
void SetNormal
(
int Index, |
Set Normal at Index to given value with given ParentVertex | Generators/MeshShapeGenerator.h | |
void SetTriangle
(
int Index, |
Generators/MeshShapeGenerator.h | ||
void SetTriangle
(
int Index, |
Generators/MeshShapeGenerator.h | ||
void SetTriangle
(
int Index, |
Generators/MeshShapeGenerator.h | ||
void SetTriangleNormals
(
int Index, |
Generators/MeshShapeGenerator.h | ||
void SetTriangleNormals
(
int Index, |
Generators/MeshShapeGenerator.h | ||
void SetTriangleNormals
(
int Index, |
Generators/MeshShapeGenerator.h | ||
void SetTrianglePolygon
(
int Index, |
Generators/MeshShapeGenerator.h | ||
void SetTriangleUVs
(
int Index, |
Generators/MeshShapeGenerator.h | ||
void SetTriangleUVs
(
int Index, |
Generators/MeshShapeGenerator.h | ||
void SetTriangleUVs
(
int Index, |
Generators/MeshShapeGenerator.h | ||
void SetTriangleWithMatchedUVNormal
(
int Index, |
Set triangle and UVs and normals with matching indices Convenience function for shapes with no uv or normal seams | Generators/MeshShapeGenerator.h | |
void SetUV
(
int Index, |
Set UV at Index to given value with given ParentVertex | Generators/MeshShapeGenerator.h | |
void SetVertex
(
int Index, |
Set vertex at Index to given Position | Generators/MeshShapeGenerator.h |
Static
| Name | Remarks | Include Path | Unreal Specifiers |
|---|---|---|---|
static FVector2f BilinearInterp
(
const FVector2f& v00, |
Generators/MeshShapeGenerator.h | ||
static FVector2d BilinearInterp
(
const FVector2d& v00, |
Generators/MeshShapeGenerator.h | ||
static FVector3d BilinearInterp
(
const FVector3d& v00, |
Generators/MeshShapeGenerator.h | ||
| Generators/MeshShapeGenerator.h |