Merge pull request #490 from IndiumGames/more-undefined-reference-errors

More undefined reference errors #490
This commit is contained in:
Angelica Wrangler 2016-03-15 09:37:46 +01:00
commit 93d09e0e93
10 changed files with 62 additions and 35 deletions

View File

@ -49,11 +49,6 @@ namespace glm
typedef tmat2x2<T, P> transpose_type; typedef tmat2x2<T, P> transpose_type;
typedef T value_type; typedef T value_type;
template <typename U, precision Q>
friend tvec2<U, Q> operator/(tmat2x2<U, Q> const & m, tvec2<U, Q> const & v);
template <typename U, precision Q>
friend tvec2<U, Q> operator/(tvec2<U, Q> const & v, tmat2x2<U, Q> const & m);
private: private:
col_type value[2]; col_type value[2];

View File

@ -177,10 +177,10 @@ namespace glm
GLM_FUNC_DECL tmat3x4<T, P> operator*(tmat2x4<T, P> const & m1, tmat3x2<T, P> const & m2); GLM_FUNC_DECL tmat3x4<T, P> operator*(tmat2x4<T, P> const & m1, tmat3x2<T, P> const & m2);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tmat2x4<T, P> operator/(tmat2x4<T, P> const & m, const T& s); GLM_FUNC_DECL tmat2x4<T, P> operator/(tmat2x4<T, P> const & m, T const & s);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tmat2x4<T, P> operator/(T s, tmat2x4<T, P> const & m); GLM_FUNC_DECL tmat2x4<T, P> operator/(T const & s, tmat2x4<T, P> const & m);
// -- Boolean operators -- // -- Boolean operators --

View File

@ -493,7 +493,7 @@ namespace glm
} }
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_QUALIFIER tmat2x4<T, P> operator/(tmat2x4<T, P> const & m, const T& s) GLM_FUNC_QUALIFIER tmat2x4<T, P> operator/(tmat2x4<T, P> const & m, T const & s)
{ {
return tmat2x4<T, P>( return tmat2x4<T, P>(
m[0] / s, m[0] / s,
@ -501,7 +501,7 @@ namespace glm
} }
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_QUALIFIER tmat2x4<T, P> operator/(T s, tmat2x4<T, P> const & m) GLM_FUNC_QUALIFIER tmat2x4<T, P> operator/(T const & s, tmat2x4<T, P> const & m)
{ {
return tmat2x4<T, P>( return tmat2x4<T, P>(
s / m[0], s / m[0],

View File

@ -49,11 +49,6 @@ namespace glm
typedef tmat3x3<T, P> transpose_type; typedef tmat3x3<T, P> transpose_type;
typedef T value_type; typedef T value_type;
template <typename U, precision Q>
friend tvec3<U, Q> operator/(tmat3x3<U, Q> const & m, tvec3<U, Q> const & v);
template <typename U, precision Q>
friend tvec3<U, Q> operator/(tvec3<U, Q> const & v, tmat3x3<U, Q> const & m);
private: private:
col_type value[3]; col_type value[3];

View File

@ -49,11 +49,6 @@ namespace glm
typedef tmat4x4<T, P> transpose_type; typedef tmat4x4<T, P> transpose_type;
typedef T value_type; typedef T value_type;
template <typename U, precision Q>
friend tvec4<U, Q> operator/(tmat4x4<U, Q> const & m, tvec4<U, Q> const & v);
template <typename U, precision Q>
friend tvec4<U, Q> operator/(tvec4<U, Q> const & v, tmat4x4<U, Q> const & m);
private: private:
col_type value[4]; col_type value[4];
@ -210,7 +205,7 @@ namespace glm
GLM_FUNC_DECL typename tmat4x4<T, P>::col_type operator/(tmat4x4<T, P> const & m, typename tmat4x4<T, P>::row_type const & v); GLM_FUNC_DECL typename tmat4x4<T, P>::col_type operator/(tmat4x4<T, P> const & m, typename tmat4x4<T, P>::row_type const & v);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL typename tmat4x4<T, P>::row_type operator/(typename tmat4x4<T, P>::col_type & v, tmat4x4<T, P> const & m); GLM_FUNC_DECL typename tmat4x4<T, P>::row_type operator/(typename tmat4x4<T, P>::col_type const & v, tmat4x4<T, P> const & m);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tmat4x4<T, P> operator/(tmat4x4<T, P> const & m1, tmat4x4<T, P> const & m2); GLM_FUNC_DECL tmat4x4<T, P> operator/(tmat4x4<T, P> const & m1, tmat4x4<T, P> const & m2);

View File

@ -346,7 +346,7 @@ namespace detail
// -- Binary operators -- // -- Binary operators --
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator+(tvec4<T, P> const & v, const T& scalar); GLM_FUNC_DECL tvec4<T, P> operator+(tvec4<T, P> const & v, T scalar);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator+(tvec4<T, P> const & v1, tvec1<T, P> const & v2); GLM_FUNC_DECL tvec4<T, P> operator+(tvec4<T, P> const & v1, tvec1<T, P> const & v2);
@ -361,7 +361,7 @@ namespace detail
GLM_FUNC_DECL tvec4<T, P> operator+(tvec4<T, P> const & v1, tvec4<T, P> const & v2); GLM_FUNC_DECL tvec4<T, P> operator+(tvec4<T, P> const & v1, tvec4<T, P> const & v2);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator-(tvec4<T, P> const & v, const T& scalar); GLM_FUNC_DECL tvec4<T, P> operator-(tvec4<T, P> const & v, T scalar);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator-(tvec4<T, P> const & v1, tvec1<T, P> const & v2); GLM_FUNC_DECL tvec4<T, P> operator-(tvec4<T, P> const & v1, tvec1<T, P> const & v2);
@ -376,7 +376,7 @@ namespace detail
GLM_FUNC_DECL tvec4<T, P> operator-(tvec4<T, P> const & v1, tvec4<T, P> const & v2); GLM_FUNC_DECL tvec4<T, P> operator-(tvec4<T, P> const & v1, tvec4<T, P> const & v2);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator*(tvec4<T, P> const & v, const T& scalar); GLM_FUNC_DECL tvec4<T, P> operator*(tvec4<T, P> const & v, T scalar);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator*(tvec4<T, P> const & v1, tvec1<T, P> const & v2); GLM_FUNC_DECL tvec4<T, P> operator*(tvec4<T, P> const & v1, tvec1<T, P> const & v2);
@ -391,16 +391,16 @@ namespace detail
GLM_FUNC_DECL tvec4<T, P> operator*(tvec4<T, P> const & v1, tvec4<T, P> const & v2); GLM_FUNC_DECL tvec4<T, P> operator*(tvec4<T, P> const & v1, tvec4<T, P> const & v2);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator/(tvec4<T, P> const & v, const T& scalar); GLM_FUNC_DECL tvec4<T, P> operator/(tvec4<T, P> const & v, T scalar);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator/(tvec4<T, P> const & v, tvec1<T, P> const & scalar); GLM_FUNC_DECL tvec4<T, P> operator/(tvec4<T, P> const & v1, tvec1<T, P> const & v2);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator/(T scalar, tvec4<T, P> const & v); GLM_FUNC_DECL tvec4<T, P> operator/(T scalar, tvec4<T, P> const & v);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator/(tvec1<T, P> const & scalar, tvec4<T, P> const & v); GLM_FUNC_DECL tvec4<T, P> operator/(tvec1<T, P> const & v1, tvec4<T, P> const & v2);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator/(tvec4<T, P> const & v1, tvec4<T, P> const & v2); GLM_FUNC_DECL tvec4<T, P> operator/(tvec4<T, P> const & v1, tvec4<T, P> const & v2);

View File

@ -642,7 +642,7 @@ namespace glm
// -- Binary arithmetic operators -- // -- Binary arithmetic operators --
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_QUALIFIER tvec4<T, P> operator+(tvec4<T, P> const & v, const T& scalar) GLM_FUNC_QUALIFIER tvec4<T, P> operator+(tvec4<T, P> const & v, T scalar)
{ {
return tvec4<T, P>( return tvec4<T, P>(
v.x + scalar, v.x + scalar,
@ -692,7 +692,7 @@ namespace glm
} }
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_QUALIFIER tvec4<T, P> operator-(tvec4<T, P> const & v, const T& scalar) GLM_FUNC_QUALIFIER tvec4<T, P> operator-(tvec4<T, P> const & v, T scalar)
{ {
return tvec4<T, P>( return tvec4<T, P>(
v.x - scalar, v.x - scalar,
@ -742,7 +742,7 @@ namespace glm
} }
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_QUALIFIER tvec4<T, P> operator*(tvec4<T, P> const & v, const T& scalar) GLM_FUNC_QUALIFIER tvec4<T, P> operator*(tvec4<T, P> const & v, T scalar)
{ {
return tvec4<T, P>( return tvec4<T, P>(
v.x * scalar, v.x * scalar,
@ -792,7 +792,7 @@ namespace glm
} }
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_QUALIFIER tvec4<T, P> operator/(tvec4<T, P> const & v, const T& scalar) GLM_FUNC_QUALIFIER tvec4<T, P> operator/(tvec4<T, P> const & v, T scalar)
{ {
return tvec4<T, P>( return tvec4<T, P>(
v.x / scalar, v.x / scalar,
@ -801,6 +801,16 @@ namespace glm
v.w / scalar); v.w / scalar);
} }
template <typename T, precision P>
GLM_FUNC_QUALIFIER tvec4<T, P> operator/(tvec4<T, P> const & v1, tvec1<T, P> const & v2)
{
return tvec4<T, P>(
v1.x / v2.x,
v1.y / v2.x,
v1.z / v2.x,
v1.w / v2.x);
}
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_QUALIFIER tvec4<T, P> operator/(T scalar, tvec4<T, P> const & v) GLM_FUNC_QUALIFIER tvec4<T, P> operator/(T scalar, tvec4<T, P> const & v)
{ {
@ -811,6 +821,16 @@ namespace glm
scalar / v.w); scalar / v.w);
} }
template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator/(tvec1<T, P> const & v1, tvec4<T, P> const & v2)
{
return tvec4<T, P>(
v1.x / v2.x,
v1.x / v2.y,
v1.x / v2.z,
v1.x / v2.w);
}
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_QUALIFIER tvec4<T, P> operator/(tvec4<T, P> const & v1, tvec4<T, P> const & v2) GLM_FUNC_QUALIFIER tvec4<T, P> operator/(tvec4<T, P> const & v1, tvec4<T, P> const & v2)
{ {

View File

@ -170,6 +170,14 @@ namespace glm
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tquat<T, P> operator/(tquat<T, P> const & q, T const & s); GLM_FUNC_DECL tquat<T, P> operator/(tquat<T, P> const & q, T const & s);
// -- Boolean operators --
template <typename T, precision P>
GLM_FUNC_DECL bool operator==(tquat<T, P> const & q1, tquat<T, P> const & q2);
template <typename T, precision P>
GLM_FUNC_DECL bool operator!=(tquat<T, P> const & q1, tquat<T, P> const & q2);
/// Returns the length of the quaternion. /// Returns the length of the quaternion.
/// ///
/// @see gtc_quaternion /// @see gtc_quaternion

View File

@ -130,16 +130,16 @@ namespace glm
GLM_FUNC_DECL tdualquat<T, P> operator*(tdualquat<T, P> const & q, tdualquat<T, P> const & p); GLM_FUNC_DECL tdualquat<T, P> operator*(tdualquat<T, P> const & q, tdualquat<T, P> const & p);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec3<T, P> operator*(tquat<T, P> const & q, tvec3<T, P> const & v); GLM_FUNC_DECL tvec3<T, P> operator*(tdualquat<T, P> const & q, tvec3<T, P> const & v);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec3<T, P> operator*(tvec3<T, P> const & v, tquat<T, P> const & q); GLM_FUNC_DECL tvec3<T, P> operator*(tvec3<T, P> const & v, tdualquat<T, P> const & q);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator*(tquat<T, P> const & q, tvec4<T, P> const & v); GLM_FUNC_DECL tvec4<T, P> operator*(tdualquat<T, P> const & q, tvec4<T, P> const & v);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tvec4<T, P> operator*(tvec4<T, P> const & v, tquat<T, P> const & q); GLM_FUNC_DECL tvec4<T, P> operator*(tvec4<T, P> const & v, tdualquat<T, P> const & q);
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tdualquat<T, P> operator*(tdualquat<T, P> const & q, T const & s); GLM_FUNC_DECL tdualquat<T, P> operator*(tdualquat<T, P> const & q, T const & s);
@ -150,6 +150,14 @@ namespace glm
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_DECL tdualquat<T, P> operator/(tdualquat<T, P> const & q, T const & s); GLM_FUNC_DECL tdualquat<T, P> operator/(tdualquat<T, P> const & q, T const & s);
// -- Boolean operators --
template <typename T, precision P>
GLM_FUNC_DECL bool operator==(tdualquat<T, P> const & q1, tdualquat<T, P> const & q2);
template <typename T, precision P>
GLM_FUNC_DECL bool operator!=(tdualquat<T, P> const & q1, tdualquat<T, P> const & q2);
/// Returns the normalized quaternion. /// Returns the normalized quaternion.
/// ///
/// @see gtx_dual_quaternion /// @see gtx_dual_quaternion

View File

@ -194,11 +194,17 @@ namespace glm
// -- Unary bit operators -- // -- Unary bit operators --
template <typename T, precision P> template <typename T, precision P>
GLM_FUNC_QUALIFIER tdualquat<T, P> operator-(tdualquat<T, P> const & q) GLM_FUNC_QUALIFIER tdualquat<T, P> operator+(tdualquat<T, P> const & q)
{ {
return q; return q;
} }
template <typename T, precision P>
GLM_FUNC_QUALIFIER tdualquat<T, P> operator-(tdualquat<T, P> const & q)
{
return tdualquat<T, P>(-q.real, -q.dual);
}
// -- Binary operators -- // -- Binary operators --
template <typename T, precision P> template <typename T, precision P>