UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
UE::Anim::Compression Namespace Reference

Functions

ENGINE_API bool CompressAnimationDataTracks (TArray< FRawAnimSequenceTrack > &RawAnimationData, int32 NumberOfKeys, FName ErrorName, float MaxPosDiff=0.0001f, float MaxAngleDiff=0.0003f, float MaxScaleDiff=0.0001f)
 
ENGINE_API bool CompressAnimationDataTracks (const USkeleton *Skeleton, const TArray< FTrackToSkeletonMap > &TrackToSkeleton, TArray< FRawAnimSequenceTrack > &RawAnimationData, int32 NumberOfKeys, FName ErrorName, float MaxPosDiff=0.0001f, float MaxAngleDiff=0.0003f, float MaxScaleDiff=0.0001f)
 
ENGINE_API bool CompressRawAnimSequenceTrack (FRawAnimSequenceTrack &RawTrack, int32 NumberOfKeys, FName ErrorName, float MaxPosDiff, float MaxAngleDiff)
 
ENGINE_API bool CompressRawAnimSequenceTrack (FRawAnimSequenceTrack &RawTrack, int32 NumberOfKeys, FName ErrorName, float MaxPosDiff, float MaxAngleDiff, float MaxScaleDiff)
 
ENGINE_API void SanitizeRawAnimSequenceTrack (FRawAnimSequenceTrack &RawTrack)
 

Function Documentation

◆ CompressAnimationDataTracks() [1/2]

bool UE::Anim::Compression::CompressAnimationDataTracks ( const USkeleton Skeleton,
const TArray< FTrackToSkeletonMap > &  TrackToSkeleton,
TArray< FRawAnimSequenceTrack > &  RawAnimationData,
int32  NumberOfKeys,
FName  ErrorName,
float  MaxPosDiff = 0.0001f,
float  MaxAngleDiff = 0.0003f,
float  MaxScaleDiff = 0.0001f 
)

Compress the provided tracks using two methods.

  1. Checking for uniform key data according to the provided error metrics
  2. Setting number of scale keys to 0 if it is uniform, equal to FVector::OneVector and matches the Skeleton reference bone pose(s)
Parameters
RawAnimationDataSet of tracks to apply the reduction to
NumberOfKeysExpected number of keys for each component within the tracks
ErrorNameIdentifier for outer callsite when failing to reduce the data
MaxPosDiffMaximum positional delta when determining whether or not two positional keys are identical
MaxAngleDiffMaximum rotational delta when determining whether or not two rotational keys are identical
Returns
Whether or not the operation was succesful

◆ CompressAnimationDataTracks() [2/2]

bool UE::Anim::Compression::CompressAnimationDataTracks ( TArray< FRawAnimSequenceTrack > &  RawAnimationData,
int32  NumberOfKeys,
FName  ErrorName,
float  MaxPosDiff = 0.0001f,
float  MaxAngleDiff = 0.0003f,
float  MaxScaleDiff = 0.0001f 
)

Compress the provided tracks using two methods.

  1. Checking for uniform key data according to the provided error metrics
  2. Setting number of scale keys to 0 if it is uniform and equal to FVector::OneVector
Parameters
RawAnimationDataSet of tracks to apply the reduction to
NumberOfKeysExpected number of keys for each component within the tracks
ErrorNameIdentifier for outer callsite when failing to reduce the data
MaxPosDiffMaximum positional delta when determining whether or not two positional keys are identical
MaxAngleDiffMaximum rotational delta when determining whether or not two rotational keys are identical
Returns
Whether or not the operation was succesful

◆ CompressRawAnimSequenceTrack() [1/2]

bool UE::Anim::Compression::CompressRawAnimSequenceTrack ( FRawAnimSequenceTrack RawTrack,
int32  NumberOfKeys,
FName  ErrorName,
float  MaxPosDiff,
float  MaxAngleDiff 
)

Compress the provided track by checking for uniform key data according to the provided error metrics

Parameters
RawTrackIndividual track to apply the reduction to
NumberOfKeysExpected number of keys for each component within the tracks
ErrorNameIdentifier for outer callsite when failing to reduce the data
MaxPosDiffMaximum positional delta when determining whether or not two positional keys are identical
MaxAngleDiffMaximum rotational delta when determining whether or not two rotational keys are identical
Returns
Whether or not the operation was succesful

◆ CompressRawAnimSequenceTrack() [2/2]

bool UE::Anim::Compression::CompressRawAnimSequenceTrack ( FRawAnimSequenceTrack RawTrack,
int32  NumberOfKeys,
FName  ErrorName,
float  MaxPosDiff,
float  MaxAngleDiff,
float  MaxScaleDiff 
)

Compress the provided track by checking for uniform key data according to the provided error metrics

Parameters
RawTrackIndividual track to apply the reduction to
NumberOfKeysExpected number of keys for each component within the tracks
ErrorNameIdentifier for outer callsite when failing to reduce the data
MaxPosDiffMaximum positional delta when determining whether or not two positional keys are identical
MaxAngleDiffMaximum rotational delta when determining whether or not two rotational keys are identical
MaxScaleDiffMaximum scale delta when determining whether or not two scale keys are identical
Returns
Whether or not the operation was succesful

◆ SanitizeRawAnimSequenceTrack()

void UE::Anim::Compression::SanitizeRawAnimSequenceTrack ( FRawAnimSequenceTrack RawTrack)

Sanitize the provided track by snapping small scale values to 0, and normalizing any rotational keys

Parameters
RawTrackIndividual track to sanitize