Ark Server API (ASA) - Wiki
Loading...
Searching...
No Matches
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"
+ Include dependency graph for InterpCurvePoint.h:
+ This graph shows which files directly or indirectly include this file:

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 = 0x0 , CIM_CurveAuto = 0x1 , CIM_Constant = 0x2 , CIM_CurveUser = 0x3 ,
  CIM_CurveBreak = 0x4 , CIM_CurveAutoClamped = 0x5 , CIM_Unknown = 0x6 , CIM_Linear ,
  CIM_Linear = 0x0 , CIM_CurveAuto , CIM_CurveAuto = 0x1 , CIM_Constant ,
  CIM_Constant = 0x2 , CIM_CurveUser , CIM_CurveUser = 0x3 , CIM_CurveBreak ,
  CIM_CurveBreak = 0x4 , CIM_CurveAutoClamped , CIM_CurveAutoClamped = 0x5 , CIM_Unknown ,
  CIM_Unknown = 0x6
}
 

Functions

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 CurveFloatFindIntervalBounds (const FInterpCurvePoint< float > &Start, const FInterpCurvePoint< float > &End, float &CurrentMin, float &CurrentMax)
 
void CurveVector2DFindIntervalBounds (const FInterpCurvePoint< FVector2D > &Start, const FInterpCurvePoint< FVector2D > &End, FVector2D &CurrentMin, FVector2D &CurrentMax)
 
void CurveVectorFindIntervalBounds (const FInterpCurvePoint< FVector > &Start, const FInterpCurvePoint< FVector > &End, FVector &CurrentMin, FVector &CurrentMax)
 
void CurveTwoVectorsFindIntervalBounds (const FInterpCurvePoint< FTwoVectors > &Start, const FInterpCurvePoint< FTwoVectors > &End, FTwoVectors &CurrentMin, FTwoVectors &CurrentMax)
 
void 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 
CIM_CurveAuto 
CIM_Constant 
CIM_CurveUser 
CIM_CurveBreak 
CIM_CurveAutoClamped 
CIM_Unknown 
CIM_Linear 

A straight line between two keypoint values.

CIM_Linear 
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_CurveAuto 
CIM_Constant 

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

CIM_Constant 
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_CurveUser 
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_CurveBreak 
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_CurveAutoClamped 
CIM_Unknown 

Invalid or unknown curve type.

CIM_Unknown 

Definition at line 15 of file InterpCurvePoint.h.

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

Definition at line 206 of file InterpCurvePoint.h.

◆ 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

Definition at line 196 of file InterpCurvePoint.h.

◆ ClampFloatTangent()

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.

Definition at line 236 of file InterpCurvePoint.h.

◆ 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.

Definition at line 284 of file InterpCurvePoint.h.

◆ 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.

Definition at line 332 of file InterpCurvePoint.h.

◆ 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.

Definition at line 300 of file InterpCurvePoint.h.

◆ 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.

Definition at line 316 of file InterpCurvePoint.h.

◆ 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.

Definition at line 214 of file InterpCurvePoint.h.

◆ CurveFindIntervalBounds() [1/6]

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

Definition at line 435 of file InterpCurvePoint.h.

◆ CurveFindIntervalBounds() [2/6]

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

Definition at line 407 of file InterpCurvePoint.h.

◆ CurveFindIntervalBounds() [3/6]

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

Definition at line 428 of file InterpCurvePoint.h.

◆ CurveFindIntervalBounds() [4/6]

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

Definition at line 421 of file InterpCurvePoint.h.

◆ CurveFindIntervalBounds() [5/6]

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

Definition at line 414 of file InterpCurvePoint.h.

◆ 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

Definition at line 402 of file InterpCurvePoint.h.

◆ CurveFloatFindIntervalBounds()

void 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 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 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 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 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