engine
 
载入中...
搜索中...
未找到
函数
CommonAnimationLibrary 命名空间参考

A library of the most common animation functions. 更多...

函数

ANIMGRAPHRUNTIME_API FVector RetargetSingleLocation (FVector Location, const FTransform &Source, const FTransform &Target, const FRuntimeFloatCurve &CustomCurve, EEasingFuncType EasingType=EEasingFuncType::Linear, bool bFlipEasing=false, float EasingWeight=1.f, FVector Axis=FVector(1.f, 0.f, 0.f), float SourceMinimum=-1.f, float SourceMaximum=1.f, float TargetMinimum=-1.f, float TargetMaximum=1.f)
 This function performs retargeting of translation using an easing function. 更多...
 
ANIMGRAPHRUNTIME_API FQuat RetargetSingleRotation (const FQuat &Rotation, const FTransform &Source, const FTransform &Target, const FRuntimeFloatCurve &CustomCurve, EEasingFuncType EasingType=EEasingFuncType::Linear, bool bFlipEasing=false, float EasingWeight=1.f, ERotationComponent RotationComponent=ERotationComponent::SwingAngle, FVector TwistAxis=FVector(1.f, 0.f, 0.f), bool bUseAbsoluteAngle=false, float SourceMinimum=0.0f, float SourceMaximum=45.f, float TargetMinimum=0.f, float TargetMaximum=45.f)
 This function performs retargeting of rotation using an easing function. 更多...
 
ANIMGRAPHRUNTIME_API float ScalarEasing (float Value, const FRuntimeFloatCurve &CustomCurve, EEasingFuncType EasingType=EEasingFuncType::Linear, bool bFlip=false, float Weight=1.f)
 This function perform easing on a float value using a variety of easing types. 更多...
 

详细描述

A library of the most common animation functions.

函数说明

◆ RetargetSingleLocation()

ANIMGRAPHRUNTIME_API FVector CommonAnimationLibrary::RetargetSingleLocation ( FVector  Location,
const FTransform &  Source,
const FTransform &  Target,
const FRuntimeFloatCurve &  CustomCurve,
EEasingFuncType  EasingType = EEasingFuncType::Linear,
bool  bFlipEasing = false,
float  EasingWeight = 1.f,
FVector  Axis = FVector(1.f, 0.f, 0.f),
float  SourceMinimum = -1.f,
float  SourceMaximum = 1.f,
float  TargetMinimum = -1.f,
float  TargetMaximum = 1.f 
)

This function performs retargeting of translation using an easing function.

For this a range of motion needs to be defined given a direction and the constraints.

参数
LocationThe input location to be retargeted
SourceThe transform to be used as the frame of reference
TargetThe transform to be used as the target space
AxisThe direction to use for the range measurement. Defaults to (1.0, 0.0, 0.0)
SourceMinimumThe minimum of the source range
SourceMaximumThe maximum of the source range
TargetMinimumThe minimum of the target range
TargetMaximumThe maximum of the target range
EasingTypeThe type of easing to apply
CustomCurveThe curve to use if the easing type is "Custom"
bFlipEasingIf set to true the easing is flipping around
EasingWeightThe amount of easing to use against linear (0.0 to 1.0)

◆ RetargetSingleRotation()

ANIMGRAPHRUNTIME_API FQuat CommonAnimationLibrary::RetargetSingleRotation ( const FQuat &  Rotation,
const FTransform &  Source,
const FTransform &  Target,
const FRuntimeFloatCurve &  CustomCurve,
EEasingFuncType  EasingType = EEasingFuncType::Linear,
bool  bFlipEasing = false,
float  EasingWeight = 1.f,
ERotationComponent  RotationComponent = ERotationComponent::SwingAngle,
FVector  TwistAxis = FVector(1.f, 0.f, 0.f),
bool  bUseAbsoluteAngle = false,
float  SourceMinimum = 0.0f,
float  SourceMaximum = 45.f,
float  TargetMinimum = 0.f,
float  TargetMaximum = 45.f 
)

This function performs retargeting of rotation using an easing function.

For this a range of motion needs to be defined as a euler angle, swing angle or twist

参数
RotationThe input rotation to be retargeted
SourceThe transform to be used as the frame of reference
TargetThe transform to be used as the target space
CustomCurveThe curve to use if the easing type is "Custom"
bFlipEasingIf set to true the easing is flipping around
EasingWeightThe amount of easing to use against linear (0.0 to 1.0)
RotationComponentThe component of the rotation to retarget
TwistAxisThe axis to use when extracting swing / twist rotations
bUseAbsoluteAngleIf set to true negative angles will be flipped to positive. This can be used to mirror the rotation.
SourceMinimumThe minimum of the source range in degrees
SourceMaximumThe maximum of the source range in degrees
TargetMinimumThe minimum of the target range in degrees
TargetMaximumThe maximum of the target range in degrees
EasingTypeThe type of easing to apply

◆ ScalarEasing()

ANIMGRAPHRUNTIME_API float CommonAnimationLibrary::ScalarEasing ( float  Value,
const FRuntimeFloatCurve &  CustomCurve,
EEasingFuncType  EasingType = EEasingFuncType::Linear,
bool  bFlip = false,
float  Weight = 1.f 
)

This function perform easing on a float value using a variety of easing types.

参数
ValueThe float value to ease
EasingTypeThe easing function to use
CustomCurveThe curve to use if the easing type is "Custom"
bFlipIf set to true the easing is flipping around
WeightThe amount of easing to use against linear (0.0 to 1.0)