Skip to content

LiteFX::Math::align

Aligns a value size to an alignment alignment.

Synopsis

Declared in <litefx/math.hpp>

template<typename T = UInt32>
constexpr static T align(
    T size,
    T alignment);

Return Value

The aligned value.

Template Parameters

NameDescription
TThe type of the value to align.

Parameters

NameDescription
sizeThe value to align.
alignmentThe alignment to align the value to.