Lugdunum  0.1.0
Classes | Namespaces | Macros | Functions
Vector.hpp File Reference
#include <cstdint>
#include <lug/Math/Matrix.hpp>
#include <lug/Math/Vector.inl>
Include dependency graph for Vector.hpp:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  lug::Math::Vector< Rows, T >
 

Namespaces

 lug
 
 lug::Math
 

Macros

#define DEFINE_ACCESS(name, minimum_rows)
 
#define DEFINE_LENGTH_VECTOR(length)
 

Functions

template<typename T >
constexpr Vector< 3, T > lug::Math::cross (const Vector< 3, T > &lhs, const Vector< 3, T > &rhs)
 
template<uint8_t Rows, typename T >
constexpr T lug::Math::dot (const Vector< Rows, T > &lhs, const Vector< Rows, T > &rhs)
 
template<uint8_t Rows, uint8_t Columns, typename T >
constexpr Matrix< Rows, Columns, T > lug::Math::outer (const Vector< Rows, T > &lhs, const Vector< Columns, T > &rhs)
 
template<uint8_t Rows, typename T >
constexpr Vector< Rows, T > lug::Math::normalize (const Vector< Rows, T > &lhs)
 
template<uint8_t Rows, typename T >
Vector< Rows, T > lug::Math::operator* (const Vector< Rows, T > &lhs, const Vector< Rows, T > &rhs)
 
template<uint8_t Rows, typename T >
Vector< Rows, T > lug::Math::operator/ (const Vector< Rows, T > &lhs, const Vector< Rows, T > &rhs)
 
template<uint8_t Rows, typename T >
Vector< Rows, T > lug::Math::operator* (const Vector< Rows, T > &lhs, const Matrix< Rows, Rows, T > &rhs)
 
template<uint8_t Rows, typename T >
Vector< Rows, T > lug::Math::operator* (const Matrix< Rows, Rows, T > &lhs, const Vector< Rows, T > &rhs)
 
template<typename T >
Vector< 3, T > lug::Math::operator* (const Vector< 3, T > &lhs, const Matrix< 4, 4, T > &rhs)
 
template<typename T >
Vector< 3, T > lug::Math::operator* (const Matrix< 4, 4, T > &lhs, const Vector< 3, T > &rhs)
 

Macro Definition Documentation

◆ DEFINE_ACCESS

#define DEFINE_ACCESS (   name,
  minimum_rows 
)
Value:
template <bool EnableBool = true, typename = typename std::enable_if<(Rows >= minimum_rows) && EnableBool>::type> \
const T& name() const { \
return (*this)(minimum_rows - 1); \
} \
\
template <bool EnableBool = true, typename = typename std::enable_if<(Rows >= minimum_rows) && EnableBool>::type> \
T& name() { \
return (*this)(minimum_rows - 1); \
}

Definition at line 41 of file Vector.hpp.

◆ DEFINE_LENGTH_VECTOR

#define DEFINE_LENGTH_VECTOR (   length)
Value:
template <typename T = float> \
using Vec##length = Vector<length, T>; \
\
template class LUG_MATH_API Vector<length, float>; \
using Vec##length##f = Vec##length<float>; \
\
template class LUG_MATH_API Vector<length, double>; \
using Vec##length##d = Vec##length<double>; \
\
template class LUG_MATH_API Vector<length, int32_t>; \
using Vec##length##i = Vec##length<int32_t>; \
\
template class LUG_MATH_API Vector<length, uint32_t>; \
using Vec##length##u = Vec##length<uint32_t>;
#define LUG_MATH_API
Definition: Export.hpp:11

Definition at line 85 of file Vector.hpp.