# TConvexHull2

References

 Module GeometryAlgorithms Header /Engine/Plugins/Experimental/GeometryProcessing/Source/GeometryAlgorithms/Public/ConvexHull2.h Include #include "ConvexHull2.h"

Syntax

template<typename RealType>
class TConvexHull2

Variables

Name Description

int32

Dimension

Hull

int32

NumUniquePoints

Functions

Name Description

void

Empty()

Empty any previously-computed convex hull data.

int32

GetDimension()

void

GetHull

(
TFunctionRef< FVector2< RealType >(...,
TArray< int32 >& Merged,
int32& IdxFirst,
int32& IdxLast
)

Divide-and-conquer algorithm

int32

GetNumUniquePoints()

Number of unique points considered by convex hull construction (excludes exact duplicate points and filtered-out points)

TArray< int3...

GetPolygonIndices()

void

GetTangent

(
TFunctionRef< FVector2< RealType >(...,
TArray< int32 >& Merged,
int32 j0,
int32 j1,
int32 j2,
int32 j3,
int32& i0,
int32& i1
)

bool

IsSolutionAvailable()

void

Merge

(
TFunctionRef< FVector2< RealType >(...,
TArray< int32 >& Merged,
int32 j0,
int32 j1,
int32 j2,
int32 j3,
int32& i0,
int32& i1
)

bool

Solve

(
TArrayView< const FVector2< RealTyp...
)

Default FilterFunc version of the above Solve(); workaround for clang bug https://bugs.llvm.org/show_bug.cgi?id=25333

bool

Solve

(
TArrayView< const FVector2< RealTyp...,
TFunctionRef< bool)> FilterFu...
)

Generate convex hull as long as input is not degenerate If input is degenerate, this will return false, and caller can call GetDimension() to determine whether the points were collinear, or all the same point

bool

Solve

(
int32 NumPoints,
TFunctionRef< FVector2< RealType >(...,
TFunctionRef< bool)> FilterFu...
)

Generate convex hull as long as input is not degenerate If input is degenerate, this will return false, and caller can call GetDimension() to determine whether the points were collinear, or all the same point

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