UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
InterpCurvePoint.h File Reference
#include "CoreTypes.h"
#include "HAL/UnrealMemory.h"
#include "Math/UnrealMathUtility.h"
#include "Math/Color.h"
#include "Math/Vector2D.h"
#include "Containers/EnumAsByte.h"
#include "Math/Vector.h"
#include "Math/Quat.h"
#include "Math/TwoVectors.h"

Go to the source code of this file.

Classes

class  FInterpCurvePoint< T >
 

Typedefs

typedef FInterpCurvePoint< floatFInterpCurvePointFloat
 
typedef FInterpCurvePoint< FVector2DFInterpCurvePointVector2D
 
typedef FInterpCurvePoint< FVectorFInterpCurvePointVector
 
typedef FInterpCurvePoint< FQuatFInterpCurvePointQuat
 
typedef FInterpCurvePoint< FTwoVectorsFInterpCurvePointTwoVectors
 
typedef FInterpCurvePoint< FLinearColorFInterpCurvePointLinearColor
 

Enumerations

enum  EInterpCurveMode {
  CIM_Linear , CIM_CurveAuto , CIM_Constant , CIM_CurveUser ,
  CIM_CurveBreak , CIM_CurveAutoClamped , CIM_Unknown
}
 

Functions

CORE_API float ClampFloatTangent (float PrevPointVal, float PrevTime, float CurPointVal, float CurTime, float NextPointVal, float NextTime)
 
template<class T , class U >
void AutoCalcTangent (const T &PrevP, const T &P, const T &NextP, const U &Tension, T &OutTan)
 
template<class U >
void AutoCalcTangent (const FQuat &PrevP, const FQuat &P, const FQuat &NextP, const U &Tension, FQuat &OutTan)
 
template<class T >
void ComputeCurveTangent (float PrevTime, const T &PrevPoint, float CurTime, const T &CurPoint, float NextTime, const T &NextPoint, float Tension, bool bWantClamping, T &OutTangent)
 
template<class T >
void ComputeClampableFloatVectorCurveTangent (float PrevTime, const T &PrevPoint, float CurTime, const T &CurPoint, float NextTime, const T &NextPoint, float Tension, bool bWantClamping, T &OutTangent)
 
void ComputeCurveTangent (float PrevTime, const float &PrevPoint, float CurTime, const float &CurPoint, float NextTime, const float &NextPoint, float Tension, bool bWantClamping, float &OutTangent)
 
void ComputeCurveTangent (float PrevTime, const FVector &PrevPoint, float CurTime, const FVector &CurPoint, float NextTime, const FVector &NextPoint, float Tension, bool bWantClamping, FVector &OutTangent)
 
void ComputeCurveTangent (float PrevTime, const FVector2D &PrevPoint, float CurTime, const FVector2D &CurPoint, float NextTime, const FVector2D &NextPoint, float Tension, bool bWantClamping, FVector2D &OutTangent)
 
void ComputeCurveTangent (float PrevTime, const FTwoVectors &PrevPoint, float CurTime, const FTwoVectors &CurPoint, float NextTime, const FTwoVectors &NextPoint, float Tension, bool bWantClamping, FTwoVectors &OutTangent)
 
void CORE_API CurveFloatFindIntervalBounds (const FInterpCurvePoint< float > &Start, const FInterpCurvePoint< float > &End, float &CurrentMin, float &CurrentMax)
 
void CORE_API CurveVector2DFindIntervalBounds (const FInterpCurvePoint< FVector2D > &Start, const FInterpCurvePoint< FVector2D > &End, FVector2D &CurrentMin, FVector2D &CurrentMax)
 
void CORE_API CurveVectorFindIntervalBounds (const FInterpCurvePoint< FVector > &Start, const FInterpCurvePoint< FVector > &End, FVector &CurrentMin, FVector &CurrentMax)
 
void CORE_API CurveTwoVectorsFindIntervalBounds (const FInterpCurvePoint< FTwoVectors > &Start, const FInterpCurvePoint< FTwoVectors > &End, FTwoVectors &CurrentMin, FTwoVectors &CurrentMax)
 
void CORE_API CurveLinearColorFindIntervalBounds (const FInterpCurvePoint< FLinearColor > &Start, const FInterpCurvePoint< FLinearColor > &End, FLinearColor &CurrentMin, FLinearColor &CurrentMax)
 
template<class T , class U >
void CurveFindIntervalBounds (const FInterpCurvePoint< T > &Start, const FInterpCurvePoint< T > &End, T &CurrentMin, T &CurrentMax, const U &Dummy)
 
template<class U >
void CurveFindIntervalBounds (const FInterpCurvePoint< float > &Start, const FInterpCurvePoint< float > &End, float &CurrentMin, float &CurrentMax, const U &Dummy)
 
template<class U >
void CurveFindIntervalBounds (const FInterpCurvePoint< FVector2D > &Start, const FInterpCurvePoint< FVector2D > &End, FVector2D &CurrentMin, FVector2D &CurrentMax, const U &Dummy)
 
template<class U >
void CurveFindIntervalBounds (const FInterpCurvePoint< FVector > &Start, const FInterpCurvePoint< FVector > &End, FVector &CurrentMin, FVector &CurrentMax, const U &Dummy)
 
template<class U >
void CurveFindIntervalBounds (const FInterpCurvePoint< FTwoVectors > &Start, const FInterpCurvePoint< FTwoVectors > &End, FTwoVectors &CurrentMin, FTwoVectors &CurrentMax, const U &Dummy)
 
template<class U >
void CurveFindIntervalBounds (const FInterpCurvePoint< FLinearColor > &Start, const FInterpCurvePoint< FLinearColor > &End, FLinearColor &CurrentMin, FLinearColor &CurrentMax, const U &Dummy)
 

Typedef Documentation

◆ FInterpCurvePointFloat

◆ FInterpCurvePointLinearColor

◆ FInterpCurvePointQuat

◆ FInterpCurvePointTwoVectors

◆ FInterpCurvePointVector

◆ FInterpCurvePointVector2D

Enumeration Type Documentation

◆ EInterpCurveMode

Enumerator
CIM_Linear 

A straight line between two keypoint values.

CIM_CurveAuto 

A cubic-hermite curve between two keypoints, using Arrive/Leave tangents. These tangents will be automatically updated when points are moved, etc. Tangents are unclamped and will plateau at curve start and end points.

CIM_Constant 

The out value is held constant until the next key, then will jump to that value.

CIM_CurveUser 

A smooth curve just like CIM_Curve, but tangents are not automatically updated so you can have manual control over them (eg. in Curve Editor).

CIM_CurveBreak 

A curve like CIM_Curve, but the arrive and leave tangents are not forced to be the same, so you can create a 'corner' at this key.

CIM_CurveAutoClamped 

A cubic-hermite curve between two keypoints, using Arrive/Leave tangents. These tangents will be automatically updated when points are moved, etc. Tangents are clamped and will plateau at curve start and end points.

CIM_Unknown 

Invalid or unknown curve type.

Function Documentation

◆ AutoCalcTangent() [1/2]

template<class U >
void AutoCalcTangent ( const FQuat PrevP,
const FQuat P,
const FQuat NextP,
const U &  Tension,
FQuat OutTan 
)
inline

This actually returns the control point not a tangent. This is expected by the CubicInterp function for Quaternions

◆ AutoCalcTangent() [2/2]

template<class T , class U >
void AutoCalcTangent ( const T &  PrevP,
const T &  P,
const T &  NextP,
const U &  Tension,
T &  OutTan 
)
inline

Computes Tangent for a curve segment

◆ ClampFloatTangent()

CORE_API float ClampFloatTangent ( float  PrevPointVal,
float  PrevTime,
float  CurPointVal,
float  CurTime,
float  NextPointVal,
float  NextTime 
)

Clamps a tangent formed by the specified control point values

◆ ComputeClampableFloatVectorCurveTangent()

template<class T >
void ComputeClampableFloatVectorCurveTangent ( float  PrevTime,
const T &  PrevPoint,
float  CurTime,
const T &  CurPoint,
float  NextTime,
const T &  NextPoint,
float  Tension,
bool  bWantClamping,
T &  OutTangent 
)
inline

Computes a tangent for the specified control point; supports clamping, but only works with floats or contiguous arrays of floats.

◆ ComputeCurveTangent() [1/5]

void ComputeCurveTangent ( float  PrevTime,
const float PrevPoint,
float  CurTime,
const float CurPoint,
float  NextTime,
const float NextPoint,
float  Tension,
bool  bWantClamping,
float OutTangent 
)
inline

Computes a tangent for the specified control point. Special case for float types; supports clamping.

◆ ComputeCurveTangent() [2/5]

void ComputeCurveTangent ( float  PrevTime,
const FTwoVectors PrevPoint,
float  CurTime,
const FTwoVectors CurPoint,
float  NextTime,
const FTwoVectors NextPoint,
float  Tension,
bool  bWantClamping,
FTwoVectors OutTangent 
)
inline

Computes a tangent for the specified control point. Special case for FTwoVectors types; supports clamping.

◆ ComputeCurveTangent() [3/5]

void ComputeCurveTangent ( float  PrevTime,
const FVector PrevPoint,
float  CurTime,
const FVector CurPoint,
float  NextTime,
const FVector NextPoint,
float  Tension,
bool  bWantClamping,
FVector OutTangent 
)
inline

Computes a tangent for the specified control point. Special case for FVector types; supports clamping.

◆ ComputeCurveTangent() [4/5]

void ComputeCurveTangent ( float  PrevTime,
const FVector2D PrevPoint,
float  CurTime,
const FVector2D CurPoint,
float  NextTime,
const FVector2D NextPoint,
float  Tension,
bool  bWantClamping,
FVector2D OutTangent 
)
inline

Computes a tangent for the specified control point. Special case for FVector2D types; supports clamping.

◆ ComputeCurveTangent() [5/5]

template<class T >
void ComputeCurveTangent ( float  PrevTime,
const T &  PrevPoint,
float  CurTime,
const T &  CurPoint,
float  NextTime,
const T &  NextPoint,
float  Tension,
bool  bWantClamping,
T &  OutTangent 
)
inline

Computes a tangent for the specified control point. General case, doesn't support clamping.

◆ CurveFindIntervalBounds() [1/6]

template<class U >
void CurveFindIntervalBounds ( const FInterpCurvePoint< FLinearColor > &  Start,
const FInterpCurvePoint< FLinearColor > &  End,
FLinearColor CurrentMin,
FLinearColor CurrentMax,
const U &  Dummy 
)
inline

◆ CurveFindIntervalBounds() [2/6]

template<class U >
void CurveFindIntervalBounds ( const FInterpCurvePoint< float > &  Start,
const FInterpCurvePoint< float > &  End,
float CurrentMin,
float CurrentMax,
const U &  Dummy 
)
inline

◆ CurveFindIntervalBounds() [3/6]

template<class U >
void CurveFindIntervalBounds ( const FInterpCurvePoint< FTwoVectors > &  Start,
const FInterpCurvePoint< FTwoVectors > &  End,
FTwoVectors CurrentMin,
FTwoVectors CurrentMax,
const U &  Dummy 
)
inline

◆ CurveFindIntervalBounds() [4/6]

template<class U >
void CurveFindIntervalBounds ( const FInterpCurvePoint< FVector > &  Start,
const FInterpCurvePoint< FVector > &  End,
FVector CurrentMin,
FVector CurrentMax,
const U &  Dummy 
)
inline

◆ CurveFindIntervalBounds() [5/6]

template<class U >
void CurveFindIntervalBounds ( const FInterpCurvePoint< FVector2D > &  Start,
const FInterpCurvePoint< FVector2D > &  End,
FVector2D CurrentMin,
FVector2D CurrentMax,
const U &  Dummy 
)

◆ CurveFindIntervalBounds() [6/6]

template<class T , class U >
void CurveFindIntervalBounds ( const FInterpCurvePoint< T > &  Start,
const FInterpCurvePoint< T > &  End,
T &  CurrentMin,
T &  CurrentMax,
const U &  Dummy 
)
inline

◆ CurveFloatFindIntervalBounds()

void CORE_API CurveFloatFindIntervalBounds ( const FInterpCurvePoint< float > &  Start,
const FInterpCurvePoint< float > &  End,
float CurrentMin,
float CurrentMax 
)

Calculate bounds of float intervals

Parameters
Startinterp curve point at Start
Endinterp curve point at End
CurrentMinInput and Output could be updated if needs new interval minimum bound
CurrentMaxInput and Output could be updated if needs new interval maximmum bound

◆ CurveLinearColorFindIntervalBounds()

void CORE_API CurveLinearColorFindIntervalBounds ( const FInterpCurvePoint< FLinearColor > &  Start,
const FInterpCurvePoint< FLinearColor > &  End,
FLinearColor CurrentMin,
FLinearColor CurrentMax 
)

Calculate bounds of color intervals

Parameters
Startinterp curve point at Start
Endinterp curve point at End
CurrentMinInput and Output could be updated if needs new interval minimum bound
CurrentMaxInput and Output could be updated if needs new interval maximmum bound

◆ CurveTwoVectorsFindIntervalBounds()

void CORE_API CurveTwoVectorsFindIntervalBounds ( const FInterpCurvePoint< FTwoVectors > &  Start,
const FInterpCurvePoint< FTwoVectors > &  End,
FTwoVectors CurrentMin,
FTwoVectors CurrentMax 
)

Calculate bounds of twovector intervals

Parameters
Startinterp curve point at Start
Endinterp curve point at End
CurrentMinInput and Output could be updated if needs new interval minimum bound
CurrentMaxInput and Output could be updated if needs new interval maximmum bound

◆ CurveVector2DFindIntervalBounds()

void CORE_API CurveVector2DFindIntervalBounds ( const FInterpCurvePoint< FVector2D > &  Start,
const FInterpCurvePoint< FVector2D > &  End,
FVector2D CurrentMin,
FVector2D CurrentMax 
)

Calculate bounds of 2D vector intervals

Parameters
Startinterp curve point at Start
Endinterp curve point at End
CurrentMinInput and Output could be updated if needs new interval minimum bound
CurrentMaxInput and Output could be updated if needs new interval maximmum bound

◆ CurveVectorFindIntervalBounds()

void CORE_API CurveVectorFindIntervalBounds ( const FInterpCurvePoint< FVector > &  Start,
const FInterpCurvePoint< FVector > &  End,
FVector CurrentMin,
FVector CurrentMax 
)

Calculate bounds of vector intervals

Parameters
Startinterp curve point at Start
Endinterp curve point at End
CurrentMinInput and Output could be updated if needs new interval minimum bound
CurrentMaxInput and Output could be updated if needs new interval maximmum bound