Fixed Visual C++ internal error when declaring a global vec type with siwzzle expression enabled #594
This commit is contained in:
@@ -738,17 +738,21 @@
|
||||
# define GLM_DEFAULT_CTOR
|
||||
#endif
|
||||
|
||||
#if GLM_HAS_CONSTEXPR
|
||||
#if GLM_HAS_CONSTEXPR || GLM_HAS_CONSTEXPR_PARTIAL
|
||||
# define GLM_CONSTEXPR constexpr
|
||||
# define GLM_CONSTEXPR_CTOR constexpr
|
||||
# define GLM_RELAXED_CONSTEXPR constexpr
|
||||
#elif GLM_HAS_CONSTEXPR_PARTIAL
|
||||
# define GLM_CONSTEXPR constexpr
|
||||
# define GLM_CONSTEXPR_CTOR
|
||||
# define GLM_RELAXED_CONSTEXPR const
|
||||
# if GLM_COMPILER & GLM_COMPILER_VC // Visual C++ has a bug #594 https://github.com/g-truc/glm/issues/594
|
||||
# define GLM_CONSTEXPR_CTOR
|
||||
# else
|
||||
# define GLM_CONSTEXPR_CTOR constexpr
|
||||
# endif
|
||||
#else
|
||||
# define GLM_CONSTEXPR
|
||||
# define GLM_CONSTEXPR_CTOR
|
||||
#endif
|
||||
|
||||
#if GLM_HAS_CONSTEXPR
|
||||
# define GLM_RELAXED_CONSTEXPR constexpr
|
||||
#else
|
||||
# define GLM_RELAXED_CONSTEXPR const
|
||||
#endif
|
||||
|
||||
|
||||
@@ -85,31 +85,31 @@ namespace glm
|
||||
|
||||
// -- Implicit basic constructors --
|
||||
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec1() GLM_DEFAULT_CTOR;
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec1(tvec1<T, P> const & v) GLM_DEFAULT;
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec1() GLM_DEFAULT_CTOR;
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec1(tvec1<T, P> const & v) GLM_DEFAULT;
|
||||
template <precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec1(tvec1<T, Q> const & v);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec1(tvec1<T, Q> const & v);
|
||||
|
||||
// -- Explicit basic constructors --
|
||||
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR explicit tvec1(ctor);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR explicit tvec1(T scalar);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR explicit tvec1(T scalar);
|
||||
|
||||
// -- Conversion vector constructors --
|
||||
|
||||
/// Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR GLM_EXPLICIT tvec1(tvec2<U, Q> const & v);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR GLM_EXPLICIT tvec1(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>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR GLM_EXPLICIT tvec1(tvec3<U, Q> const & v);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR GLM_EXPLICIT tvec1(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>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR GLM_EXPLICIT tvec1(tvec4<U, Q> const & v);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR GLM_EXPLICIT tvec1(tvec4<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>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR GLM_EXPLICIT tvec1(tvec1<U, Q> const & v);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR GLM_EXPLICIT tvec1(tvec1<U, Q> const & v);
|
||||
|
||||
// -- Swizzle constructors --
|
||||
/*
|
||||
|
||||
@@ -7,7 +7,7 @@ namespace glm
|
||||
|
||||
# if !GLM_HAS_DEFAULTED_FUNCTIONS || !defined(GLM_FORCE_NO_CTOR_INIT)
|
||||
template <typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec1<T, P>::tvec1()
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec1<T, P>::tvec1()
|
||||
# ifndef GLM_FORCE_NO_CTOR_INIT
|
||||
: x(0)
|
||||
# endif
|
||||
@@ -16,14 +16,14 @@ namespace glm
|
||||
|
||||
# if !GLM_HAS_DEFAULTED_FUNCTIONS
|
||||
template <typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec1<T, P>::tvec1(tvec1<T, P> const & v)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec1<T, P>::tvec1(tvec1<T, P> const & v)
|
||||
: x(v.x)
|
||||
{}
|
||||
# endif//!GLM_HAS_DEFAULTED_FUNCTIONS
|
||||
|
||||
template <typename T, precision P>
|
||||
template <precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec1<T, P>::tvec1(tvec1<T, Q> const & v)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec1<T, P>::tvec1(tvec1<T, Q> const & v)
|
||||
: x(v.x)
|
||||
{}
|
||||
|
||||
@@ -34,7 +34,7 @@ namespace glm
|
||||
{}
|
||||
|
||||
template <typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec1<T, P>::tvec1(T scalar)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec1<T, P>::tvec1(T scalar)
|
||||
: x(scalar)
|
||||
{}
|
||||
|
||||
@@ -42,25 +42,25 @@ namespace glm
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec1<T, P>::tvec1(tvec1<U, Q> const & v)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec1<T, P>::tvec1(tvec1<U, Q> const & v)
|
||||
: x(static_cast<T>(v.x))
|
||||
{}
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec1<T, P>::tvec1(tvec2<U, Q> const & v)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec1<T, P>::tvec1(tvec2<U, Q> const & v)
|
||||
: x(static_cast<T>(v.x))
|
||||
{}
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec1<T, P>::tvec1(tvec3<U, Q> const & v)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec1<T, P>::tvec1(tvec3<U, Q> const & v)
|
||||
: x(static_cast<T>(v.x))
|
||||
{}
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec1<T, P>::tvec1(tvec4<U, Q> const & v)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec1<T, P>::tvec1(tvec4<U, Q> const & v)
|
||||
: x(static_cast<T>(v.x))
|
||||
{}
|
||||
|
||||
|
||||
@@ -86,37 +86,37 @@ namespace glm
|
||||
|
||||
// -- Implicit basic constructors --
|
||||
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec2() GLM_DEFAULT_CTOR;
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec2(tvec2<T, P> const& v) GLM_DEFAULT;
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec2() GLM_DEFAULT_CTOR;
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec2(tvec2<T, P> const& v) GLM_DEFAULT;
|
||||
template <precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec2(tvec2<T, Q> const& v);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec2(tvec2<T, Q> const& v);
|
||||
|
||||
// -- Explicit basic constructors --
|
||||
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR explicit tvec2(ctor);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR explicit tvec2(T scalar);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec2(T s1, T s2);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR explicit tvec2(T scalar);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec2(T s1, T s2);
|
||||
|
||||
// -- Conversion constructors --
|
||||
|
||||
/// Explicit converions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename A, typename B>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec2(A x, B y);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec2(A x, B y);
|
||||
template <typename A, typename B>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec2(tvec1<A, P> const & v1, tvec1<B, P> const & v2);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec2(tvec1<A, P> const & v1, tvec1<B, P> const & v2);
|
||||
|
||||
// -- Conversion vector constructors --
|
||||
|
||||
/// Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR GLM_EXPLICIT tvec2(tvec3<U, Q> const & v);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR GLM_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>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR GLM_EXPLICIT tvec2(tvec4<U, Q> const & v);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR GLM_EXPLICIT tvec2(tvec4<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>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR GLM_EXPLICIT tvec2(tvec2<U, Q> const & v);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR GLM_EXPLICIT tvec2(tvec2<U, Q> const & v);
|
||||
|
||||
// -- Swizzle constructors --
|
||||
# if GLM_HAS_UNRESTRICTED_UNIONS && (GLM_SWIZZLE == GLM_SWIZZLE_ENABLED)
|
||||
|
||||
@@ -20,7 +20,7 @@ namespace glm
|
||||
|
||||
# if !GLM_HAS_DEFAULTED_FUNCTIONS || !defined(GLM_FORCE_NO_CTOR_INIT)
|
||||
template <typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec2<T, P>::tvec2()
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec2<T, P>::tvec2()
|
||||
# ifndef GLM_FORCE_NO_CTOR_INIT
|
||||
: x(0), y(0)
|
||||
# endif
|
||||
@@ -29,14 +29,14 @@ namespace glm
|
||||
|
||||
# if !GLM_HAS_DEFAULTED_FUNCTIONS
|
||||
template <typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec2<T, P>::tvec2(tvec2<T, P> const & v)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec2<T, P>::tvec2(tvec2<T, P> const & v)
|
||||
: x(v.x), y(v.y)
|
||||
{}
|
||||
# endif//!GLM_HAS_DEFAULTED_FUNCTIONS
|
||||
|
||||
template <typename T, precision P>
|
||||
template <precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec2<T, P>::tvec2(tvec2<T, Q> const & v)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec2<T, P>::tvec2(tvec2<T, Q> const & v)
|
||||
: x(v.x), y(v.y)
|
||||
{}
|
||||
|
||||
@@ -47,12 +47,12 @@ namespace glm
|
||||
{}
|
||||
|
||||
template <typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec2<T, P>::tvec2(T scalar)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec2<T, P>::tvec2(T scalar)
|
||||
: x(scalar), y(scalar)
|
||||
{}
|
||||
|
||||
template <typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec2<T, P>::tvec2(T s1, T s2)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec2<T, P>::tvec2(T s1, T s2)
|
||||
: x(s1), y(s2)
|
||||
{}
|
||||
|
||||
@@ -60,14 +60,14 @@ namespace glm
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec2<T, P>::tvec2(A a, B b)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec2<T, P>::tvec2(A a, B b)
|
||||
: x(static_cast<T>(a))
|
||||
, y(static_cast<T>(b))
|
||||
{}
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec2<T, P>::tvec2(tvec1<A, P> const & a, tvec1<B, P> const & b)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec2<T, P>::tvec2(tvec1<A, P> const & a, tvec1<B, P> const & b)
|
||||
: x(static_cast<T>(a.x))
|
||||
, y(static_cast<T>(b.x))
|
||||
{}
|
||||
@@ -76,21 +76,21 @@ namespace glm
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec2<T, P>::tvec2(tvec2<U, Q> const & v)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec2<T, P>::tvec2(tvec2<U, Q> const & v)
|
||||
: x(static_cast<T>(v.x))
|
||||
, y(static_cast<T>(v.y))
|
||||
{}
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec2<T, P>::tvec2(tvec3<U, Q> const & v)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec2<T, P>::tvec2(tvec3<U, Q> const & v)
|
||||
: x(static_cast<T>(v.x))
|
||||
, y(static_cast<T>(v.y))
|
||||
{}
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec2<T, P>::tvec2(tvec4<U, Q> const & v)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec2<T, P>::tvec2(tvec4<U, Q> const & v)
|
||||
: x(static_cast<T>(v.x))
|
||||
, y(static_cast<T>(v.y))
|
||||
{}
|
||||
|
||||
@@ -86,46 +86,46 @@ namespace glm
|
||||
|
||||
// -- Implicit basic constructors --
|
||||
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec3() GLM_DEFAULT_CTOR;
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec3(tvec3<T, P> const & v) GLM_DEFAULT;
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec3() GLM_DEFAULT_CTOR;
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec3(tvec3<T, P> const & v) GLM_DEFAULT;
|
||||
template <precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec3(tvec3<T, Q> const & v);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec3(tvec3<T, Q> const & v);
|
||||
|
||||
// -- Explicit basic constructors --
|
||||
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR explicit tvec3(ctor);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR explicit tvec3(T scalar);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec3(T a, T b, T c);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR explicit tvec3(T scalar);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec3(T a, T b, T c);
|
||||
|
||||
// -- Conversion scalar constructors --
|
||||
|
||||
/// Explicit converions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
/// Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename A, typename B, typename C>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec3(A a, B b, C c);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec3(A a, B b, C c);
|
||||
template <typename A, typename B, typename C>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec3(tvec1<A, P> const & a, tvec1<B, P> const & b, tvec1<C, P> const & c);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec3(tvec1<A, P> const & a, tvec1<B, P> const & b, tvec1<C, P> const & c);
|
||||
|
||||
// -- Conversion 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>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec3(tvec2<A, Q> const & a, B b);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec3(tvec2<A, Q> const & a, B b);
|
||||
/// Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec3(tvec2<A, Q> const & a, tvec1<B, Q> const & b);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec3(tvec2<A, Q> const & a, tvec1<B, Q> const & b);
|
||||
/// Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec3(A a, tvec2<B, Q> const & b);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec3(A a, tvec2<B, Q> const & b);
|
||||
/// Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec3(tvec1<A, Q> const & a, tvec2<B, Q> const & b);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec3(tvec1<A, Q> const & a, tvec2<B, Q> const & b);
|
||||
/// Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR GLM_EXPLICIT tvec3(tvec4<U, Q> const & v);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR GLM_EXPLICIT tvec3(tvec4<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>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR GLM_EXPLICIT tvec3(tvec3<U, Q> const & v);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR GLM_EXPLICIT tvec3(tvec3<U, Q> const & v);
|
||||
|
||||
// -- Swizzle constructors --
|
||||
# if GLM_HAS_UNRESTRICTED_UNIONS && (GLM_SWIZZLE == GLM_SWIZZLE_ENABLED)
|
||||
|
||||
@@ -33,7 +33,7 @@ namespace glm
|
||||
|
||||
# if !GLM_HAS_DEFAULTED_FUNCTIONS || !defined(GLM_FORCE_NO_CTOR_INIT)
|
||||
template <typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec3<T, P>::tvec3()
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec3<T, P>::tvec3()
|
||||
# ifndef GLM_FORCE_NO_CTOR_INIT
|
||||
: x(0), y(0), z(0)
|
||||
# endif
|
||||
@@ -42,14 +42,14 @@ namespace glm
|
||||
|
||||
# if !GLM_HAS_DEFAULTED_FUNCTIONS
|
||||
template <typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec3<T, P>::tvec3(tvec3<T, P> const & v)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec3<T, P>::tvec3(tvec3<T, P> const & v)
|
||||
: x(v.x), y(v.y), z(v.z)
|
||||
{}
|
||||
# endif//!GLM_HAS_DEFAULTED_FUNCTIONS
|
||||
|
||||
template <typename T, precision P>
|
||||
template <precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec3<T, P>::tvec3(tvec3<T, Q> const & v)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec3<T, P>::tvec3(tvec3<T, Q> const & v)
|
||||
: x(v.x), y(v.y), z(v.z)
|
||||
{}
|
||||
|
||||
@@ -60,12 +60,12 @@ namespace glm
|
||||
{}
|
||||
|
||||
template <typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec3<T, P>::tvec3(T scalar)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec3<T, P>::tvec3(T scalar)
|
||||
: x(scalar), y(scalar), z(scalar)
|
||||
{}
|
||||
|
||||
template <typename T, precision P>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec3<T, P>::tvec3(T a, T b, T c)
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec3<T, P>::tvec3(T a, T b, T c)
|
||||
: x(a), y(b), z(c)
|
||||
{}
|
||||
|
||||
@@ -73,7 +73,7 @@ namespace glm
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, typename C>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec3<T, P>::tvec3(A a, B b, C c) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec3<T, P>::tvec3(A a, B b, C c) :
|
||||
x(static_cast<T>(a)),
|
||||
y(static_cast<T>(b)),
|
||||
z(static_cast<T>(c))
|
||||
@@ -81,7 +81,7 @@ namespace glm
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, typename C>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec3<T, P>::tvec3(tvec1<A, P> const & a, tvec1<B, P> const & b, tvec1<C, P> const & c) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec3<T, P>::tvec3(tvec1<A, P> const & a, tvec1<B, P> const & b, tvec1<C, P> const & c) :
|
||||
x(static_cast<T>(a)),
|
||||
y(static_cast<T>(b)),
|
||||
z(static_cast<T>(c))
|
||||
@@ -91,7 +91,7 @@ namespace glm
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec3<T, P>::tvec3(tvec2<A, Q> const & a, B b) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec3<T, P>::tvec3(tvec2<A, Q> const & a, B b) :
|
||||
x(static_cast<T>(a.x)),
|
||||
y(static_cast<T>(a.y)),
|
||||
z(static_cast<T>(b))
|
||||
@@ -99,7 +99,7 @@ namespace glm
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec3<T, P>::tvec3(tvec2<A, Q> const & a, tvec1<B, Q> const & b) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec3<T, P>::tvec3(tvec2<A, Q> const & a, tvec1<B, Q> const & b) :
|
||||
x(static_cast<T>(a.x)),
|
||||
y(static_cast<T>(a.y)),
|
||||
z(static_cast<T>(b.x))
|
||||
@@ -107,7 +107,7 @@ namespace glm
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec3<T, P>::tvec3(A a, tvec2<B, Q> const & b) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec3<T, P>::tvec3(A a, tvec2<B, Q> const & b) :
|
||||
x(static_cast<T>(a)),
|
||||
y(static_cast<T>(b.x)),
|
||||
z(static_cast<T>(b.y))
|
||||
@@ -115,7 +115,7 @@ namespace glm
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec3<T, P>::tvec3(tvec1<A, Q> const & a, tvec2<B, Q> const & b) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec3<T, P>::tvec3(tvec1<A, Q> const & a, tvec2<B, Q> const & b) :
|
||||
x(static_cast<T>(a.x)),
|
||||
y(static_cast<T>(b.x)),
|
||||
z(static_cast<T>(b.y))
|
||||
@@ -123,7 +123,7 @@ namespace glm
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec3<T, P>::tvec3(tvec3<U, Q> const & v) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec3<T, P>::tvec3(tvec3<U, Q> const & v) :
|
||||
x(static_cast<T>(v.x)),
|
||||
y(static_cast<T>(v.y)),
|
||||
z(static_cast<T>(v.z))
|
||||
@@ -131,7 +131,7 @@ namespace glm
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec3<T, P>::tvec3(tvec4<U, Q> const & v) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec3<T, P>::tvec3(tvec4<U, Q> const & v) :
|
||||
x(static_cast<T>(v.x)),
|
||||
y(static_cast<T>(v.y)),
|
||||
z(static_cast<T>(v.z))
|
||||
|
||||
@@ -112,41 +112,41 @@ namespace glm
|
||||
|
||||
/// 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>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec4(tvec2<A, Q> const & a, B b, C c);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec4(tvec2<A, Q> const & a, B b, C c);
|
||||
/// 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>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec4(tvec2<A, Q> const & a, tvec1<B, Q> const & b, tvec1<C, Q> const & c);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec4(tvec2<A, Q> const & a, tvec1<B, Q> const & b, tvec1<C, Q> const & c);
|
||||
/// 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>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec4(A a, tvec2<B, Q> const & b, C c);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec4(A a, tvec2<B, Q> const & b, C c);
|
||||
/// 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>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec4(tvec1<A, Q> const & a, tvec2<B, Q> const & b, tvec1<C, Q> const & c);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec4(tvec1<A, Q> const & a, tvec2<B, Q> const & b, tvec1<C, Q> const & c);
|
||||
/// 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>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec4(A a, B b, tvec2<C, Q> const & c);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec4(A a, B b, tvec2<C, Q> const & c);
|
||||
/// 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>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec4(tvec1<A, Q> const & a, tvec1<B, Q> const & b, tvec2<C, Q> const & c);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec4(tvec1<A, Q> const & a, tvec1<B, Q> const & b, tvec2<C, Q> const & c);
|
||||
/// Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec4(tvec3<A, Q> const & a, B b);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec4(tvec3<A, Q> const & a, B b);
|
||||
/// Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec4(tvec3<A, Q> const & a, tvec1<B, Q> const & b);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec4(tvec3<A, Q> const & a, tvec1<B, Q> const & b);
|
||||
/// Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec4(A a, tvec3<B, Q> const & b);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec4(A a, tvec3<B, Q> const & b);
|
||||
/// Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec4(tvec1<A, Q> const & a, tvec3<B, Q> const & b);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec4(tvec1<A, Q> const & a, tvec3<B, Q> const & b);
|
||||
/// Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR tvec4(tvec2<A, Q> const & a, tvec2<B, Q> const & b);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR tvec4(tvec2<A, Q> const & a, tvec2<B, Q> const & b);
|
||||
|
||||
/// Explicit conversions (From section 5.4.1 Conversion and scalar constructors of GLSL 1.30.08 specification)
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR GLM_EXPLICIT tvec4(tvec4<U, Q> const& v);
|
||||
GLM_FUNC_DECL GLM_CONSTEXPR_CTOR GLM_EXPLICIT tvec4(tvec4<U, Q> const& v);
|
||||
|
||||
// -- Swizzle constructors --
|
||||
# if GLM_HAS_UNRESTRICTED_UNIONS && (GLM_SWIZZLE == GLM_SWIZZLE_ENABLED)
|
||||
|
||||
@@ -216,7 +216,7 @@ namespace detail
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, typename C, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec4<T, P>::tvec4(tvec2<A, Q> const & a, B b, C c) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec4<T, P>::tvec4(tvec2<A, Q> const & a, B b, C c) :
|
||||
x(static_cast<T>(a.x)),
|
||||
y(static_cast<T>(a.y)),
|
||||
z(static_cast<T>(b)),
|
||||
@@ -225,7 +225,7 @@ namespace detail
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, typename C, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec4<T, P>::tvec4(tvec2<A, Q> const & a, tvec1<B, Q> const & b, tvec1<C, Q> const & c) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec4<T, P>::tvec4(tvec2<A, Q> const & a, tvec1<B, Q> const & b, tvec1<C, Q> const & c) :
|
||||
x(static_cast<T>(a.x)),
|
||||
y(static_cast<T>(a.y)),
|
||||
z(static_cast<T>(b.x)),
|
||||
@@ -234,7 +234,7 @@ namespace detail
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, typename C, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec4<T, P>::tvec4(A s1, tvec2<B, Q> const & v, C s2) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec4<T, P>::tvec4(A s1, tvec2<B, Q> const & v, C s2) :
|
||||
x(static_cast<T>(s1)),
|
||||
y(static_cast<T>(v.x)),
|
||||
z(static_cast<T>(v.y)),
|
||||
@@ -243,7 +243,7 @@ namespace detail
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, typename C, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec4<T, P>::tvec4(tvec1<A, Q> const & a, tvec2<B, Q> const & b, tvec1<C, Q> const & c) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec4<T, P>::tvec4(tvec1<A, Q> const & a, tvec2<B, Q> const & b, tvec1<C, Q> const & c) :
|
||||
x(static_cast<T>(a.x)),
|
||||
y(static_cast<T>(b.x)),
|
||||
z(static_cast<T>(b.y)),
|
||||
@@ -252,7 +252,7 @@ namespace detail
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, typename C, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec4<T, P>::tvec4(A s1, B s2, tvec2<C, Q> const & v) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec4<T, P>::tvec4(A s1, B s2, tvec2<C, Q> const & v) :
|
||||
x(static_cast<T>(s1)),
|
||||
y(static_cast<T>(s2)),
|
||||
z(static_cast<T>(v.x)),
|
||||
@@ -261,7 +261,7 @@ namespace detail
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, typename C, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec4<T, P>::tvec4(tvec1<A, Q> const & a, tvec1<B, Q> const & b, tvec2<C, Q> const & c) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec4<T, P>::tvec4(tvec1<A, Q> const & a, tvec1<B, Q> const & b, tvec2<C, Q> const & c) :
|
||||
x(static_cast<T>(a.x)),
|
||||
y(static_cast<T>(b.x)),
|
||||
z(static_cast<T>(c.x)),
|
||||
@@ -270,7 +270,7 @@ namespace detail
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec4<T, P>::tvec4(tvec3<A, Q> const & a, B b) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec4<T, P>::tvec4(tvec3<A, Q> const & a, B b) :
|
||||
x(static_cast<T>(a.x)),
|
||||
y(static_cast<T>(a.y)),
|
||||
z(static_cast<T>(a.z)),
|
||||
@@ -279,7 +279,7 @@ namespace detail
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec4<T, P>::tvec4(tvec3<A, Q> const & a, tvec1<B, Q> const & b) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec4<T, P>::tvec4(tvec3<A, Q> const & a, tvec1<B, Q> const & b) :
|
||||
x(static_cast<T>(a.x)),
|
||||
y(static_cast<T>(a.y)),
|
||||
z(static_cast<T>(a.z)),
|
||||
@@ -288,7 +288,7 @@ namespace detail
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec4<T, P>::tvec4(A a, tvec3<B, Q> const & b) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec4<T, P>::tvec4(A a, tvec3<B, Q> const & b) :
|
||||
x(static_cast<T>(a)),
|
||||
y(static_cast<T>(b.x)),
|
||||
z(static_cast<T>(b.y)),
|
||||
@@ -297,7 +297,7 @@ namespace detail
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec4<T, P>::tvec4(tvec1<A, Q> const & a, tvec3<B, Q> const & b) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec4<T, P>::tvec4(tvec1<A, Q> const & a, tvec3<B, Q> const & b) :
|
||||
x(static_cast<T>(a.x)),
|
||||
y(static_cast<T>(b.x)),
|
||||
z(static_cast<T>(b.y)),
|
||||
@@ -306,7 +306,7 @@ namespace detail
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename A, typename B, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec4<T, P>::tvec4(tvec2<A, Q> const & a, tvec2<B, Q> const & b) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec4<T, P>::tvec4(tvec2<A, Q> const & a, tvec2<B, Q> const & b) :
|
||||
x(static_cast<T>(a.x)),
|
||||
y(static_cast<T>(a.y)),
|
||||
z(static_cast<T>(b.x)),
|
||||
@@ -315,7 +315,7 @@ namespace detail
|
||||
|
||||
template <typename T, precision P>
|
||||
template <typename U, precision Q>
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR tvec4<T, P>::tvec4(tvec4<U, Q> const & v) :
|
||||
GLM_FUNC_QUALIFIER GLM_CONSTEXPR_CTOR tvec4<T, P>::tvec4(tvec4<U, Q> const & v) :
|
||||
x(static_cast<T>(v.x)),
|
||||
y(static_cast<T>(v.y)),
|
||||
z(static_cast<T>(v.z)),
|
||||
|
||||
Reference in New Issue
Block a user