typedefs added
This commit is contained in:
parent
75108e7076
commit
9ddffcf4f7
@ -180,7 +180,7 @@ namespace polygun::math {
|
||||
|
||||
template <typename T, size_t N>
|
||||
Vector<T, N>& Vector<T, N>::operator=(const Vector<T, N>& other) {
|
||||
if (this != &other) { // self-assignment check
|
||||
if (this != &other) {
|
||||
m_data = other.m_data;
|
||||
}
|
||||
return *this;
|
||||
|
@ -68,8 +68,17 @@ namespace polygun::math {
|
||||
T magnitude() const;
|
||||
Vector<T, N> normalize() const;
|
||||
};
|
||||
|
||||
typedef Vector<int, 2> Vector2i;
|
||||
typedef Vector<float, 2> Vector2f;
|
||||
|
||||
typedef Vector<int, 3> Vector3i;
|
||||
typedef Vector<float, 3> Vector3f;
|
||||
|
||||
typedef Vector<int, 4> Vector4i;
|
||||
typedef Vector<float, 4> Vector4f;
|
||||
|
||||
typedef Vector<unsigned char, 4> RGBAColor;
|
||||
}
|
||||
|
||||
#include "vector.cpp"
|
||||
|
||||
#endif // POLYGUN_MATH_VECTOR_HPP
|
Loading…
Reference in New Issue
Block a user