|
|
@@ -68,77 +68,77 @@ namespace detail
|
|
|
//////////////////////////////////////
|
|
|
// Accesses
|
|
|
|
|
|
- half & operator[](size_type i);
|
|
|
- half const & operator[](size_type i) const;
|
|
|
+ GLM_FUNC_DECL half & operator[](size_type i);
|
|
|
+ GLM_FUNC_DECL half const & operator[](size_type i) const;
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Implicit basic constructors
|
|
|
|
|
|
- tvec2();
|
|
|
- tvec2(tvec2<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec2();
|
|
|
+ GLM_FUNC_DECL tvec2(tvec2<half, P> const & v);
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Explicit basic constructors
|
|
|
|
|
|
- explicit tvec2(ctor){}
|
|
|
- explicit tvec2(
|
|
|
+ GLM_FUNC_DECL explicit tvec2(ctor){}
|
|
|
+ GLM_FUNC_DECL explicit tvec2(
|
|
|
half const & s);
|
|
|
- explicit tvec2(
|
|
|
+ GLM_FUNC_DECL explicit tvec2(
|
|
|
half const & s1,
|
|
|
half const & s2);
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Swizzle constructors
|
|
|
|
|
|
- tvec2(tref2<half, P> const & r);
|
|
|
+ GLM_FUNC_DECL tvec2(tref2<half, P> const & r);
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Convertion scalar constructors
|
|
|
|
|
|
//! Explicit converions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename U>
|
|
|
- explicit tvec2(U const & x);
|
|
|
+ GLM_FUNC_DECL explicit tvec2(U const & x);
|
|
|
//! Explicit converions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
- template <typename U, typename V>
|
|
|
- explicit tvec2(U const & x, V const & y);
|
|
|
+ template <typename U, typename V>
|
|
|
+ GLM_FUNC_DECL explicit tvec2(U const & x, V const & y);
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Convertion vector constructors
|
|
|
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename U, precision Q>
|
|
|
- explicit tvec2(tvec2<U, Q> const & v);
|
|
|
+ GLM_FUNC_DECL explicit tvec2(tvec2<U, Q> const & v);
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename U, precision Q>
|
|
|
- explicit tvec2(tvec3<U, Q> const & v);
|
|
|
+ GLM_FUNC_DECL explicit tvec2(tvec3<U, Q> const & v);
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename U, precision Q>
|
|
|
- explicit tvec2(tvec4<U, Q> const & v);
|
|
|
+ GLM_FUNC_DECL explicit tvec2(tvec4<U, Q> const & v);
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Unary arithmetic operators
|
|
|
|
|
|
- tvec2<half, P>& operator= (tvec2<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec2<half, P>& operator= (tvec2<half, P> const & v);
|
|
|
|
|
|
- tvec2<half, P>& operator+=(half const & s);
|
|
|
- tvec2<half, P>& operator+=(tvec2<half, P> const & v);
|
|
|
- tvec2<half, P>& operator-=(half const & s);
|
|
|
- tvec2<half, P>& operator-=(tvec2<half, P> const & v);
|
|
|
- tvec2<half, P>& operator*=(half const & s);
|
|
|
- tvec2<half, P>& operator*=(tvec2<half, P> const & v);
|
|
|
- tvec2<half, P>& operator/=(half const & s);
|
|
|
- tvec2<half, P>& operator/=(tvec2<half, P> const & v);
|
|
|
- tvec2<half, P>& operator++();
|
|
|
- tvec2<half, P>& operator--();
|
|
|
+ GLM_FUNC_DECL tvec2<half, P>& operator+=(half const & s);
|
|
|
+ GLM_FUNC_DECL tvec2<half, P>& operator+=(tvec2<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec2<half, P>& operator-=(half const & s);
|
|
|
+ GLM_FUNC_DECL tvec2<half, P>& operator-=(tvec2<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec2<half, P>& operator*=(half const & s);
|
|
|
+ GLM_FUNC_DECL tvec2<half, P>& operator*=(tvec2<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec2<half, P>& operator/=(half const & s);
|
|
|
+ GLM_FUNC_DECL tvec2<half, P>& operator/=(tvec2<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec2<half, P>& operator++();
|
|
|
+ GLM_FUNC_DECL tvec2<half, P>& operator--();
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Swizzle operators
|
|
|
|
|
|
- half swizzle(comp X) const;
|
|
|
- tvec2<half, P> swizzle(comp X, comp Y) const;
|
|
|
- tvec3<half, P> swizzle(comp X, comp Y, comp Z) const;
|
|
|
- tvec4<half, P> swizzle(comp X, comp Y, comp Z, comp W) const;
|
|
|
- tref2<half, P> swizzle(comp X, comp Y);
|
|
|
+ GLM_FUNC_DECL half swizzle(comp X) const;
|
|
|
+ GLM_FUNC_DECL tvec2<half, P> swizzle(comp X, comp Y) const;
|
|
|
+ GLM_FUNC_DECL tvec3<half, P> swizzle(comp X, comp Y, comp Z) const;
|
|
|
+ GLM_FUNC_DECL tvec4<half, P> swizzle(comp X, comp Y, comp Z, comp W) const;
|
|
|
+ GLM_FUNC_DECL tref2<half, P> swizzle(comp X, comp Y);
|
|
|
};
|
|
|
|
|
|
template <precision P>
|
|
|
@@ -160,22 +160,22 @@ namespace detail
|
|
|
//////////////////////////////////////
|
|
|
// Accesses
|
|
|
|
|
|
- half & operator[](size_type i);
|
|
|
- half const & operator[](size_type i) const;
|
|
|
+ GLM_FUNC_DECL half & operator[](size_type i);
|
|
|
+ GLM_FUNC_DECL half const & operator[](size_type i) const;
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Implicit basic constructors
|
|
|
|
|
|
- tvec3();
|
|
|
- tvec3(tvec3<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec3();
|
|
|
+ GLM_FUNC_DECL tvec3(tvec3<half, P> const & v);
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Explicit basic constructors
|
|
|
|
|
|
- explicit tvec3(ctor){}
|
|
|
- explicit tvec3(
|
|
|
+ GLM_FUNC_DECL explicit tvec3(ctor){}
|
|
|
+ GLM_FUNC_DECL explicit tvec3(
|
|
|
half const & s);
|
|
|
- explicit tvec3(
|
|
|
+ GLM_FUNC_DECL explicit tvec3(
|
|
|
half const & s1,
|
|
|
half const & s2,
|
|
|
half const & s3);
|
|
|
@@ -183,58 +183,59 @@ namespace detail
|
|
|
//////////////////////////////////////
|
|
|
// Swizzle constructors
|
|
|
|
|
|
- tvec3(tref3<half, P> const & r);
|
|
|
+ GLM_FUNC_DECL tvec3(tref3<half, P> const & r);
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Convertion scalar constructors
|
|
|
|
|
|
//! Explicit converions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename U>
|
|
|
- explicit tvec3(U const & x);
|
|
|
+ GLM_FUNC_DECL explicit tvec3(U const & x);
|
|
|
+
|
|
|
//! Explicit converions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename U, typename V, typename W>
|
|
|
- explicit tvec3(U const & x, V const & y, W const & z);
|
|
|
+ GLM_FUNC_DECL explicit tvec3(U const & x, V const & y, W const & z);
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Convertion vector constructors
|
|
|
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename A, typename B, precision Q>
|
|
|
- explicit tvec3(tvec2<A, Q> const & v, B const & s);
|
|
|
+ GLM_FUNC_DECL explicit tvec3(tvec2<A, Q> const & v, B const & s);
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename A, typename B, precision Q>
|
|
|
- explicit tvec3(A const & s, tvec2<B, Q> const & v);
|
|
|
+ GLM_FUNC_DECL explicit tvec3(A const & s, tvec2<B, Q> const & v);
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename U, precision Q>
|
|
|
- explicit tvec3(tvec3<U, Q> const & v);
|
|
|
+ GLM_FUNC_DECL explicit tvec3(tvec3<U, Q> const & v);
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename U, precision Q>
|
|
|
- explicit tvec3(tvec4<U, Q> const & v);
|
|
|
+ GLM_FUNC_DECL explicit tvec3(tvec4<U, Q> const & v);
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Unary arithmetic operators
|
|
|
|
|
|
- tvec3<half, P>& operator= (tvec3<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec3<half, P>& operator= (tvec3<half, P> const & v);
|
|
|
|
|
|
- tvec3<half, P>& operator+=(half const & s);
|
|
|
- tvec3<half, P>& operator+=(tvec3<half, P> const & v);
|
|
|
- tvec3<half, P>& operator-=(half const & s);
|
|
|
- tvec3<half, P>& operator-=(tvec3<half, P> const & v);
|
|
|
- tvec3<half, P>& operator*=(half const & s);
|
|
|
- tvec3<half, P>& operator*=(tvec3<half, P> const & v);
|
|
|
- tvec3<half, P>& operator/=(half const & s);
|
|
|
- tvec3<half, P>& operator/=(tvec3<half, P> const & v);
|
|
|
- tvec3<half, P>& operator++();
|
|
|
- tvec3<half, P>& operator--();
|
|
|
+ GLM_FUNC_DECL tvec3<half, P>& operator+=(half const & s);
|
|
|
+ GLM_FUNC_DECL tvec3<half, P>& operator+=(tvec3<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec3<half, P>& operator-=(half const & s);
|
|
|
+ GLM_FUNC_DECL tvec3<half, P>& operator-=(tvec3<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec3<half, P>& operator*=(half const & s);
|
|
|
+ GLM_FUNC_DECL tvec3<half, P>& operator*=(tvec3<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec3<half, P>& operator/=(half const & s);
|
|
|
+ GLM_FUNC_DECL tvec3<half, P>& operator/=(tvec3<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec3<half, P>& operator++();
|
|
|
+ GLM_FUNC_DECL tvec3<half, P>& operator--();
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Swizzle operators
|
|
|
|
|
|
- half swizzle(comp X) const;
|
|
|
- tvec2<half, P> swizzle(comp X, comp Y) const;
|
|
|
- tvec3<half, P> swizzle(comp X, comp Y, comp Z) const;
|
|
|
- tvec4<half, P> swizzle(comp X, comp Y, comp Z, comp W) const;
|
|
|
- tref3<half, P> swizzle(comp X, comp Y, comp Z);
|
|
|
+ GLM_FUNC_DECL half swizzle(comp X) const;
|
|
|
+ GLM_FUNC_DECL tvec2<half, P> swizzle(comp X, comp Y) const;
|
|
|
+ GLM_FUNC_DECL tvec3<half, P> swizzle(comp X, comp Y, comp Z) const;
|
|
|
+ GLM_FUNC_DECL tvec4<half, P> swizzle(comp X, comp Y, comp Z, comp W) const;
|
|
|
+ GLM_FUNC_DECL tref3<half, P> swizzle(comp X, comp Y, comp Z);
|
|
|
};
|
|
|
|
|
|
template <precision P>
|
|
|
@@ -256,22 +257,23 @@ namespace detail
|
|
|
//////////////////////////////////////
|
|
|
// Accesses
|
|
|
|
|
|
- half & operator[](size_type i);
|
|
|
- half const & operator[](size_type i) const;
|
|
|
+ GLM_FUNC_DECL half & operator[](size_type i);
|
|
|
+ GLM_FUNC_DECL half const & operator[](size_type i) const;
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Implicit basic constructors
|
|
|
|
|
|
- tvec4();
|
|
|
- tvec4(tvec4<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec4();
|
|
|
+ GLM_FUNC_DECL tvec4(tvec4<half, P> const & v);
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Explicit basic constructors
|
|
|
|
|
|
- explicit tvec4(ctor){}
|
|
|
- explicit tvec4(
|
|
|
+
|
|
|
+ GLM_FUNC_DECL explicit tvec4(ctor){}
|
|
|
+ GLM_FUNC_DECL explicit tvec4(
|
|
|
half const & s);
|
|
|
- explicit tvec4(
|
|
|
+ GLM_FUNC_DECL explicit tvec4(
|
|
|
half const & s0,
|
|
|
half const & s1,
|
|
|
half const & s2,
|
|
|
@@ -280,67 +282,67 @@ namespace detail
|
|
|
//////////////////////////////////////
|
|
|
// Swizzle constructors
|
|
|
|
|
|
- tvec4(tref4<half, P> const & r);
|
|
|
+ GLM_FUNC_DECL tvec4(tref4<half, P> const & r);
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Convertion scalar constructors
|
|
|
|
|
|
//! Explicit converions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename U>
|
|
|
- explicit tvec4(U const & x);
|
|
|
+ GLM_FUNC_DECL explicit tvec4(U const & x);
|
|
|
//! Explicit converions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename A, typename B, typename C, typename D>
|
|
|
- explicit tvec4(A const & x, B const & y, C const & z, D const & w);
|
|
|
+ GLM_FUNC_DECL explicit tvec4(A const & x, B const & y, C const & z, D const & w);
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Convertion vector constructors
|
|
|
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename A, typename B, typename C, precision Q>
|
|
|
- explicit tvec4(tvec2<A, Q> const & v, B const & s1, C const & s2);
|
|
|
+ GLM_FUNC_DECL explicit tvec4(tvec2<A, Q> const & v, B const & s1, C const & s2);
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename A, typename B, typename C, precision Q>
|
|
|
- explicit tvec4(A const & s1, tvec2<B, Q> const & v, C const & s2);
|
|
|
+ GLM_FUNC_DECL explicit tvec4(A const & s1, tvec2<B, Q> const & v, C const & s2);
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename A, typename B, typename C, precision Q>
|
|
|
- explicit tvec4(A const & s1, B const & s2, tvec2<C, Q> const & v);
|
|
|
+ GLM_FUNC_DECL explicit tvec4(A const & s1, B const & s2, tvec2<C, Q> const & v);
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename A, typename B, precision Q>
|
|
|
- explicit tvec4(tvec3<A, Q> const & v, B const & s);
|
|
|
+ GLM_FUNC_DECL explicit tvec4(tvec3<A, Q> const & v, B const & s);
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename A, typename B, precision Q>
|
|
|
- explicit tvec4(A const & s, tvec3<B, Q> const & v);
|
|
|
+ GLM_FUNC_DECL explicit tvec4(A const & s, tvec3<B, Q> const & v);
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename A, typename B, precision Q>
|
|
|
- explicit tvec4(tvec2<A, Q> const & v1, tvec2<B, Q> const & v2);
|
|
|
+ GLM_FUNC_DECL explicit tvec4(tvec2<A, Q> const & v1, tvec2<B, Q> const & v2);
|
|
|
//! Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
|
|
template <typename U, precision Q>
|
|
|
- explicit tvec4(tvec4<U, Q> const & v);
|
|
|
+ GLM_FUNC_DECL explicit tvec4(tvec4<U, Q> const & v);
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Unary arithmetic operators
|
|
|
|
|
|
- tvec4<half, P>& operator= (tvec4<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec4<half, P>& operator= (tvec4<half, P> const & v);
|
|
|
|
|
|
- tvec4<half, P>& operator+=(half const & s);
|
|
|
- tvec4<half, P>& operator+=(tvec4<half, P> const & v);
|
|
|
- tvec4<half, P>& operator-=(half const & s);
|
|
|
- tvec4<half, P>& operator-=(tvec4<half, P> const & v);
|
|
|
- tvec4<half, P>& operator*=(half const & s);
|
|
|
- tvec4<half, P>& operator*=(tvec4<half, P> const & v);
|
|
|
- tvec4<half, P>& operator/=(half const & s);
|
|
|
- tvec4<half, P>& operator/=(tvec4<half, P> const & v);
|
|
|
- tvec4<half, P>& operator++();
|
|
|
- tvec4<half, P>& operator--();
|
|
|
+ GLM_FUNC_DECL tvec4<half, P>& operator+=(half const & s);
|
|
|
+ GLM_FUNC_DECL tvec4<half, P>& operator+=(tvec4<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec4<half, P>& operator-=(half const & s);
|
|
|
+ GLM_FUNC_DECL tvec4<half, P>& operator-=(tvec4<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec4<half, P>& operator*=(half const & s);
|
|
|
+ GLM_FUNC_DECL tvec4<half, P>& operator*=(tvec4<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec4<half, P>& operator/=(half const & s);
|
|
|
+ GLM_FUNC_DECL tvec4<half, P>& operator/=(tvec4<half, P> const & v);
|
|
|
+ GLM_FUNC_DECL tvec4<half, P>& operator++();
|
|
|
+ GLM_FUNC_DECL tvec4<half, P>& operator--();
|
|
|
|
|
|
//////////////////////////////////////
|
|
|
// Swizzle operators
|
|
|
|
|
|
- half swizzle(comp X) const;
|
|
|
- tvec2<half, P> swizzle(comp X, comp Y) const;
|
|
|
- tvec3<half, P> swizzle(comp X, comp Y, comp Z) const;
|
|
|
- tvec4<half, P> swizzle(comp X, comp Y, comp Z, comp W) const;
|
|
|
- tref4<half, P> swizzle(comp X, comp Y, comp Z, comp W);
|
|
|
+ GLM_FUNC_DECL half swizzle(comp X) const;
|
|
|
+ GLM_FUNC_DECL tvec2<half, P> swizzle(comp X, comp Y) const;
|
|
|
+ GLM_FUNC_DECL tvec3<half, P> swizzle(comp X, comp Y, comp Z) const;
|
|
|
+ GLM_FUNC_DECL tvec4<half, P> swizzle(comp X, comp Y, comp Z, comp W) const;
|
|
|
+ GLM_FUNC_DECL tref4<half, P> swizzle(comp X, comp Y, comp Z, comp W);
|
|
|
};
|
|
|
#endif//(GLM_COMPONENT == GLM_COMPONENT_CXX98)
|
|
|
}
|
|
|
@@ -647,19 +649,19 @@ namespace detail
|
|
|
|
|
|
/// Returns the absolute value of a half-precision floating-point value
|
|
|
/// @see gtc_half_float
|
|
|
- half abs(half const & x);
|
|
|
+ GLM_FUNC_DECL half abs(half const & x);
|
|
|
|
|
|
/// Returns the absolute value of a half-precision floating-point two dimensional vector
|
|
|
/// @see gtc_half_float
|
|
|
- hvec2 abs(hvec2 const & x);
|
|
|
+ GLM_FUNC_DECL hvec2 abs(hvec2 const & x);
|
|
|
|
|
|
/// Returns the absolute value of a half-precision floating-point three dimensional vector
|
|
|
/// @see gtc_half_float
|
|
|
- hvec3 abs(hvec3 const & x);
|
|
|
+ GLM_FUNC_DECL hvec3 abs(hvec3 const & x);
|
|
|
|
|
|
/// Returns the absolute value of a half-precision floating-point four dimensional vector
|
|
|
/// @see gtc_half_float
|
|
|
- hvec4 abs(hvec4 const & x);
|
|
|
+ GLM_FUNC_DECL hvec4 abs(hvec4 const & x);
|
|
|
|
|
|
/// Selects which vector each returned component comes
|
|
|
/// from. For a component of <a> that is false, the
|
|
|
@@ -673,7 +675,7 @@ namespace detail
|
|
|
/// where a is a Boolean vector.
|
|
|
///
|
|
|
/// @see gtc_half_float
|
|
|
- half mix(half const & x, half const & y, bool const & a);
|
|
|
+ GLM_FUNC_DECL half mix(half const & x, half const & y, bool const & a);
|
|
|
|
|
|
/// @}
|
|
|
}// namespace glm
|