vec3
Fully qualified name: omni::math::linalg::vec3
-
template<typename T>
class vec3 : public omni::math::linalg::base_vec<T, 3>
-
Public Functions
-
vec3() = default
-
constexpr vec3(const this_type&) = default
-
inline constexpr vec3(const base_type &other)
-
inline explicit constexpr vec3(T value)
-
inline constexpr vec3(T v0, T v1, T v2)
-
template<typename OTHER_T>
inline explicit constexpr vec3(
- const OTHER_T *p,
)
-
template<typename OTHER_T>
inline explicit vec3(
- const vec3<OTHER_T> &other,
)
-
template<typename OTHER_T>
inline explicit vec3(
- const base_vec<OTHER_T, 3> &other,
)
-
template<typename OTHER_T>
inline vec3(
- const std::initializer_list<OTHER_T> &other,
)
-
inline this_type &Set(T v0, T v1, T v2)
-
inline this_type &Set(T *p)
-
template<typename OTHER_T>
inline bool operator==(
- const vec3<OTHER_T> &other,
) const
-
template<typename OTHER_T>
inline bool operator!=(
- const vec3<OTHER_T> &other,
) const
-
inline this_type GetProjection(const this_type &unitVector) const
-
inline this_type GetComplement(const this_type &unitVector) const
-
inline this_type GetNormalized() const
-
void BuildOrthonormalFrame(
- vec3<T> *v1,
- vec3<T> *v2,
- float eps = 1e-10,
) const
-
inline constexpr T &operator[](size_t i) noexcept
-
inline constexpr const T &operator[](size_t i) const noexcept
-
inline constexpr T *data() noexcept
-
inline constexpr const T *data() const noexcept
-
inline const T *GetArray() const
-
inline constexpr T Dot(const base_vec<T, N> &other) const
-
inline constexpr T GetLengthSq() const
-
inline auto GetLength() const
-
inline auto Normalize()
-
inline constexpr T operator*(const base_vec<T, N> &other) const
-
inline constexpr base_vec<T, N> &operator+=(
- const base_vec<T, N> &that,
) noexcept
-
inline constexpr base_vec<T, N> &operator-=(
- const base_vec<T, N> &that,
) noexcept
-
inline constexpr base_vec<T, N> &operator*=(const T that) noexcept
-
inline constexpr base_vec<T, N> &operator/=(const T that) noexcept
Public Static Functions
-
static inline constexpr vec3<T> XAxis()
-
static inline constexpr vec3<T> YAxis()
-
static inline constexpr vec3<T> ZAxis()
-
static inline vec3<T> Axis(size_t axis)
-
static bool OrthogonalizeBasis(
- vec3<T> *pa,
- vec3<T> *pb,
- vec3<T> *pc,
- bool normalize = true,
)
Public Static Attributes
-
static constexpr size_t tuple_size
-
static const size_t dimension
Protected Attributes
-
T v[N]