UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
UE::Geometry::TVectorSetAnalysis3< RealType > Class Template Reference

#include <VectorSetAnalysis.h>

Public Member Functions

template<typename EnumerableIDType >
void Initialize (EnumerableIDType EnumerableIDs, TFunctionRef< TVector< RealType >(int32)> GetVectorFunc, int32 NumVectorsHint=0, bool bIsNormalizedHint=false)
 
int32 NumVectors () const
 
int32 NumClusters () const
 
void GreedyClusterVectors (RealType AngleToleranceDeg)
 

Public Attributes

TArray< TVector< RealType > > Vectors
 
TArray< int32VectorIDs
 
bool bNormalized = false
 
TArray< TVector< RealType > > ClusterVectors
 
TArray< int32VectorToClusterMap
 

Detailed Description

template<typename RealType>
class UE::Geometry::TVectorSetAnalysis3< RealType >

TVectorSetAnalysis3 computes various analyses of a set of input Vectors (currently mainly clustering.

Member Function Documentation

◆ GreedyClusterVectors()

template<typename RealType >
void UE::Geometry::TVectorSetAnalysis3< RealType >::GreedyClusterVectors ( RealType  AngleToleranceDeg)
inline

Run simple greedy clustering algorithm on input ClusterVectors. Done in a single pass over vectors, each successive Vector is either grouped with one of the existing clusters if it's direction is within AngleToleranceDeg, or creates a new cluster.

◆ Initialize()

template<typename RealType >
void UE::Geometry::TVectorSetAnalysis3< RealType >::Initialize ( EnumerableIDType  EnumerableIDs,
TFunctionRef< TVector< RealType >(int32)>  GetVectorFunc,
int32  NumVectorsHint = 0,
bool  bIsNormalizedHint = false 
)
inline

Initialize the internal set of Vectors and IDs using an external integer-Enumerable and associated GetVector(ID) function

Parameters
NumVectorsHintprovide hint as to number of elements in Enumerable, to allow memory to be pre-allocated
bIsNormalizedHintindicate whether vectors are normalized

◆ NumClusters()

template<typename RealType >
int32 UE::Geometry::TVectorSetAnalysis3< RealType >::NumClusters ( ) const
inline
Returns
number of clusters found by last clustering algorithm (may be zero if not initialized)

◆ NumVectors()

template<typename RealType >
int32 UE::Geometry::TVectorSetAnalysis3< RealType >::NumVectors ( ) const
inline
Returns
number of input vectors

Member Data Documentation

◆ bNormalized

template<typename RealType >
bool UE::Geometry::TVectorSetAnalysis3< RealType >::bNormalized = false

◆ ClusterVectors

template<typename RealType >
TArray<TVector<RealType> > UE::Geometry::TVectorSetAnalysis3< RealType >::ClusterVectors

Set of vectors that represent centers of clusters

◆ VectorIDs

template<typename RealType >
TArray<int32> UE::Geometry::TVectorSetAnalysis3< RealType >::VectorIDs

◆ Vectors

template<typename RealType >
TArray<TVector<RealType> > UE::Geometry::TVectorSetAnalysis3< RealType >::Vectors

◆ VectorToClusterMap

template<typename RealType >
TArray<int32> UE::Geometry::TVectorSetAnalysis3< RealType >::VectorToClusterMap

Mapping from Vector index to ClusterVectors index


The documentation for this class was generated from the following file: