UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
UE::Geometry::Spline::Math Namespace Reference

Classes

struct  FSplineValidation
 
struct  TBezierDerivativeCalculator
 
struct  TBSplineDerivativeCalculator
 
struct  TBSplineDerivativeCalculator< T, 0 >
 
struct  TGenericDerivativeHelper
 

Functions

template<typename T >
double Size (const T &Value)
 
template<typename T >
double SizeSquared (const T &Value)
 
template<typename T >
double Distance (const T &A, const T &B)
 
template<typename T >
double CentripetalDistance (const T &A, const T &B)
 
template<typename T >
double Dot (const T &A, const T &B)
 
template<typename T >
GetSafeNormal (const T &Value)
 
template<typename T >
bool Equals (const T &A, const T &B, float Tolerance=UE_KINDA_SMALL_NUMBER)
 
template<int32 N>
const TArray< double > & GetFactorialTable ()
 
template<int32 N>
const TArray< TArray< double > > & GetBinomialTable ()
 
template<typename ValueType >
float FindNearestPoint_Cubic (const TArrayView< ValueType > Coeffs, float StartParam, float EndParam, float &OutSquaredDistance)
 
template<typename ValueType >
ValueType ComputeFirstDerivativeCentralDifference (const TSplineInterface< ValueType > &Spline, double Param, double Step=UE_KINDA_SMALL_NUMBER)
 
template<typename ValueType >
ValueType ComputeSecondDerivativeCentralDifference (const TSplineInterface< ValueType > &Spline, double Param, double Step=0.1)
 

Function Documentation

◆ CentripetalDistance()

template<typename T >
double UE::Geometry::Spline::Math::CentripetalDistance ( const T &  A,
const T &  B 
)

Centripetal distance calculation (for parameterization)

◆ ComputeFirstDerivativeCentralDifference()

template<typename ValueType >
ValueType UE::Geometry::Spline::Math::ComputeFirstDerivativeCentralDifference ( const TSplineInterface< ValueType > &  Spline,
double  Param,
double  Step = UE_KINDA_SMALL_NUMBER 
)

◆ ComputeSecondDerivativeCentralDifference()

template<typename ValueType >
ValueType UE::Geometry::Spline::Math::ComputeSecondDerivativeCentralDifference ( const TSplineInterface< ValueType > &  Spline,
double  Param,
double  Step = 0.1 
)

◆ Distance()

template<typename T >
double UE::Geometry::Spline::Math::Distance ( const T &  A,
const T &  B 
)

Distance between values

◆ Dot()

template<typename T >
double UE::Geometry::Spline::Math::Dot ( const T &  A,
const T &  B 
)

Dot product between values

◆ Equals()

template<typename T >
bool UE::Geometry::Spline::Math::Equals ( const T &  A,
const T &  B,
float  Tolerance = UE_KINDA_SMALL_NUMBER 
)

Check if two values are equal within tolerance

◆ FindNearestPoint_Cubic()

template<typename ValueType >
float UE::Geometry::Spline::Math::FindNearestPoint_Cubic ( const TArrayView< ValueType >  Coeffs,
float  StartParam,
float  EndParam,
float OutSquaredDistance 
)

Find nearest point on a cubic Bezier curve segment to a target point

Parameters
Coeffs- Array of 4 coefficients in Bezier form relative to target point
StartParam- Start parameter of segment
EndParam- End parameter of segment
OutSquaredDistance- Output squared distance to nearest point
Returns
Parameter at nearest point between StartParam and EndParam

◆ GetBinomialTable()

template<int32 N>
const TArray< TArray< double > > & UE::Geometry::Spline::Math::GetBinomialTable ( )

◆ GetFactorialTable()

template<int32 N>
const TArray< double > & UE::Geometry::Spline::Math::GetFactorialTable ( )

◆ GetSafeNormal()

template<typename T >
T UE::Geometry::Spline::Math::GetSafeNormal ( const T &  Value)

Get normalized version of a value

◆ Size()

template<typename T >
double UE::Geometry::Spline::Math::Size ( const T &  Value)

Size/magnitude of a value

◆ SizeSquared()

template<typename T >
double UE::Geometry::Spline::Math::SizeSquared ( const T &  Value)

Squared size (optimization to avoid sqrt)