Skip to content

LiteFX::Math::Vector::Vector

Constructors

Synopses

Declared in <litefx/vector.hpp>

Initializes an empty vector.

constexpr Vector() noexcept = default;

» more...

Initializes a vector with the values provided by another vector.

constexpr Vector(Vector const& _other) = default;

» more...

Initializes a vector by taking over another vector.

constexpr Vector(Vector&& _other) noexcept = default;

» more...

Initializes a vector where all elements take the value provided by val.

constexpr Vector(T val) noexcept;

» more...

Initializes the vector from an arbitrary input range.

constexpr explicit Vector(auto&& input) noexcept
requires std::is_nothrow_convertible_v<std::ranges::range_value_t<decltype(input)>, T>;

» more...

Initializes a 2D vector using the values provided by x and y.

constexpr Vector(
    T x,
    T y) noexcept
requires (DIM == 2);

» more...

Initializes a 3D vector using the values provided by x, y and z.

constexpr Vector(
    T x,
    T y,
    T z) noexcept
requires (DIM == 3);

» more...

Initializes a 4D vector using the values provided by x, y, z and w.

constexpr Vector(
    T x,
    T y,
    T z,
    T w) noexcept
requires (DIM == 4);

» more...

Parameters

NameDescription
_otherThe other vector to copy the values from.
valThe value to initialize all elements of the vector with.
inputThe range to initialize the vector with.
xThe value to initialize the x-component of the vector with.
yThe value to initialize the y-component of the vector with.
zThe value to initialize the z-component of the vector with.
wThe value to initialize the w-component of the vector with.