FAnimationCompression_PerTrackUtils::CompressFixed16

Log2MaxValue of 0 => -1..1 Log2MaxValue of 7 => -128..128 Can be 0..15 Compresses a float into a signed fixed point number, which can range from the symmetrical values of -2^Log2MaxValue ..

Windows
MacOS
Linux

References

Module

Engine

Header

/Engine/Source/Runtime/Engine/Public/AnimationCompression.h

Include

#include "AnimationCompression.h"

Syntax

static uint16 CompressFixed16
(
    float Value,
    int32 Log2MaxValue
)

Remarks

Log2MaxValue of 0 => -1..1 Log2MaxValue of 7 => -128..128 Can be 0..15 Compresses a float into a signed fixed point number, which can range from the symmetrical values of -2^Log2MaxValue .. 2^Log2MaxValue. No clamping is done, values that don't fit will overflow.

For example, a Log2MaxValue of 0 can encode -1..1, and 7 can encode -128..128.

Returns

The quantized value

Parameters

Parameter

Description

Value

Value to encode

Log2MaxValue

Encoding range (can be 0..15)

Help shape the future of Unreal Engine documentation! Tell us how we're doing so we can serve you better.
Take our survey
Dismiss