39 #       if GLM_HAS_ANONYMOUS_UNION 
   56 #       if GLM_ARCH & GLM_ARCH_SSE2 
   70                 struct simd<unsigned int>
 
   76 #       if GLM_ARCH & GLM_ARCH_AVX 
   84 #       if GLM_ARCH & GLM_ARCH_AVX2 
  100         template <
typename T, precision P = defaultp>
 
  106                 typedef tvec4<T, P> type;
 
  107                 typedef tvec4<bool, P> bool_type;
 
  108                 typedef T value_type;
 
  113 #               if GLM_HAS_ANONYMOUS_UNION 
  116                                 typename detail::simd<T>::type data;
 
  117                                 struct { T r, g, b, a; };
 
  118                                 struct { T s, t, p, q; };
 
  119                                 struct { T x, y, z, w;};
 
  122                                         _GLM_SWIZZLE4_2_MEMBERS(T, P, tvec2, x, y, z, w)
 
  123                                         _GLM_SWIZZLE4_2_MEMBERS(T, P, tvec2, r, g, b, a)
 
  124                                         _GLM_SWIZZLE4_2_MEMBERS(T, P, tvec2, s, t, p, q)
 
  125                                         _GLM_SWIZZLE4_3_MEMBERS(T, P, tvec3, x, y, z, w)
 
  126                                         _GLM_SWIZZLE4_3_MEMBERS(T, P, tvec3, r, g, b, a)
 
  127                                         _GLM_SWIZZLE4_3_MEMBERS(T, P, tvec3, s, t, p, q)
 
  128                                         _GLM_SWIZZLE4_4_MEMBERS(T, P, tvec4, x, y, z, w)
 
  129                                         _GLM_SWIZZLE4_4_MEMBERS(T, P, tvec4, r, g, b, a)
 
  130                                         _GLM_SWIZZLE4_4_MEMBERS(T, P, tvec4, s, t, p, q)
 
  134                         union { T x, r, s; };
 
  135                         union { T y, g, t; };
 
  136                         union { T z, b, p; };
 
  137                         union { T w, a, q; };
 
  140                                 GLM_SWIZZLE_GEN_VEC_FROM_VEC4(T, P, tvec4, tvec2, tvec3, tvec4)
 
  147 #               ifdef GLM_FORCE_SIZE_FUNC 
  148                         typedef size_t size_type;
 
  150                         GLM_FUNC_DECL GLM_CONSTEXPR size_type size() 
const;
 
  152                         GLM_FUNC_DECL T & operator[](size_type i);
 
  153                         GLM_FUNC_DECL T 
const & operator[](size_type i) 
const;
 
  155                         typedef length_t length_type;
 
  157                         GLM_FUNC_DECL GLM_CONSTEXPR length_type 
length() 
const;
 
  159                         GLM_FUNC_DECL T & operator[](length_type i);
 
  160                         GLM_FUNC_DECL T 
const & operator[](length_type i) 
const;
 
  161 #               endif//GLM_FORCE_SIZE_FUNC 
  166                 GLM_FUNC_DECL tvec4();
 
  167                 template <precision Q>
 
  168                 GLM_FUNC_DECL tvec4(tvec4<T, Q> 
const & v);
 
  173                 GLM_FUNC_DECL 
explicit tvec4(ctor);
 
  174                 GLM_FUNC_DECL 
explicit tvec4(T s);
 
  175                 GLM_FUNC_DECL tvec4(T a, T b, T c, T d);
 
  176                 GLM_FUNC_DECL ~tvec4(){}
 
  182                 template <
typename A, 
typename B, 
typename C, 
typename D>
 
  183                 GLM_FUNC_DECL tvec4(A a, B b, C c, D d);
 
  184                 template <
typename A, 
typename B, 
typename C, 
typename D>
 
  185                 GLM_FUNC_DECL tvec4(tvec1<A, P> 
const & a, tvec1<B, P> 
const & b, tvec1<C, P> 
const & c, tvec1<D, P> 
const & d);
 
  191                 template <
typename A, 
typename B, 
typename C, precision Q>
 
  192                 GLM_FUNC_DECL 
explicit tvec4(tvec2<A, Q> 
const & a, B b, C c);
 
  194                 template <
typename A, 
typename B, 
typename C, precision Q>
 
  195                 GLM_FUNC_DECL 
explicit tvec4(tvec2<A, Q> 
const & a, tvec1<B, Q> 
const & b, tvec1<C, Q> 
const & c);
 
  197                 template <
typename A, 
typename B, 
typename C, precision Q>
 
  198                 GLM_FUNC_DECL 
explicit tvec4(A a, tvec2<B, Q> 
const & b, C c);
 
  200                 template <
typename A, 
typename B, 
typename C, precision Q>
 
  201                 GLM_FUNC_DECL 
explicit tvec4(tvec1<A, Q> 
const & a, tvec2<B, Q> 
const & b, tvec1<C, Q> 
const & c);
 
  203                 template <
typename A, 
typename B, 
typename C, precision Q>
 
  204                 GLM_FUNC_DECL 
explicit tvec4(A a, B b, tvec2<C, Q> 
const & c);
 
  206                 template <
typename A, 
typename B, 
typename C, precision Q>
 
  207                 GLM_FUNC_DECL 
explicit tvec4(tvec1<A, Q> 
const & a, tvec1<B, Q> 
const & b, tvec2<C, Q> 
const & c);
 
  209                 template <
typename A, 
typename B, precision Q>
 
  210                 GLM_FUNC_DECL 
explicit tvec4(tvec3<A, Q> 
const & a, B b);
 
  212                 template <
typename A, 
typename B, precision Q>
 
  213                 GLM_FUNC_DECL 
explicit tvec4(tvec3<A, Q> 
const & a, tvec1<B, Q> 
const & b);
 
  215                 template <
typename A, 
typename B, precision Q>
 
  216                 GLM_FUNC_DECL 
explicit tvec4(A a, tvec3<B, Q> 
const & b);
 
  218                 template <
typename A, 
typename B, precision Q>
 
  219                 GLM_FUNC_DECL 
explicit tvec4(tvec1<A, Q> 
const & a, tvec3<B, Q> 
const & b);
 
  221                 template <
typename A, 
typename B, precision Q>
 
  222                 GLM_FUNC_DECL 
explicit tvec4(tvec2<A, Q> 
const & a, tvec2<B, Q> 
const & b);
 
  224 #               ifdef GLM_FORCE_EXPLICIT_CTOR 
  225                         template <
typename U, precision Q>
 
  227                         GLM_FUNC_DECL 
explicit tvec4(tvec4<U, Q> 
const & v);
 
  229                         template <
typename U, precision Q>
 
  231                         GLM_FUNC_DECL tvec4(tvec4<U, Q> 
const & v);
 
  237 #               if GLM_HAS_ANONYMOUS_UNION && defined(GLM_SWIZZLE) 
  238                         template <
int E0, 
int E1, 
int E2, 
int E3>
 
  239                         GLM_FUNC_DECL tvec4(detail::_swizzle<4, T, P, tvec4<T, P>, E0, E1, E2, E3> 
const & that)
 
  244                         template <
int E0, 
int E1, 
int F0, 
int F1>
 
  245                         GLM_FUNC_DECL tvec4(detail::_swizzle<2, T, P, tvec2<T, P>, E0, E1, -1, -2> 
const & v, detail::_swizzle<2, T, P, tvec2<T, P>, F0, F1, -1, -2> 
const & u)
 
  247                                 *
this = tvec4<T, P>(v(), u());
 
  250                         template <
int E0, 
int E1>
 
  251                         GLM_FUNC_DECL tvec4(T 
const & x, T 
const & y, detail::_swizzle<2, T, P, tvec2<T, P>, E0, E1, -1, -2> 
const & v)
 
  253                                 *
this = tvec4<T, P>(x, y, v());
 
  256                         template <
int E0, 
int E1>
 
  257                         GLM_FUNC_DECL tvec4(T 
const & x, detail::_swizzle<2, T, P, tvec2<T, P>, E0, E1, -1, -2> 
const & v, T 
const & w)
 
  259                                 *
this = tvec4<T, P>(x, v(), w);
 
  262                         template <
int E0, 
int E1>
 
  263                         GLM_FUNC_DECL tvec4(detail::_swizzle<2, T, P, tvec2<T, P>, E0, E1, -1, -2> 
const & v, T 
const & z, T 
const & w)
 
  265                                 *
this = tvec4<T, P>(v(), z, w);
 
  268                         template <
int E0, 
int E1, 
int E2>
 
  269                         GLM_FUNC_DECL tvec4(detail::_swizzle<3, T, P, tvec3<T, P>, E0, E1, E2, -1> 
const & v, T 
const & w)
 
  271                                 *
this = tvec4<T, P>(v(), w);
 
  274                         template <
int E0, 
int E1, 
int E2>
 
  275                         GLM_FUNC_DECL tvec4(T 
const & x, detail::_swizzle<3, T, P, tvec3<T, P>, E0, E1, E2, -1> 
const & v)
 
  277                                 *
this = tvec4<T, P>(x, v());
 
  279 #               endif// GLM_HAS_ANONYMOUS_UNION && defined(GLM_SWIZZLE) 
  284                 template <
typename U>
 
  285                 GLM_FUNC_DECL tvec4<T, P> & operator=(tvec4<U, P> 
const & v);
 
  286                 template <
typename U>
 
  287                 GLM_FUNC_DECL tvec4<T, P> & operator+=(U scalar);
 
  288                 template <
typename U>
 
  289                 GLM_FUNC_DECL tvec4<T, P> & operator+=(tvec1<U, P> 
const & v);
 
  290                 template <
typename U>
 
  291                 GLM_FUNC_DECL tvec4<T, P> & operator+=(tvec4<U, P> 
const & v);
 
  292                 template <
typename U>
 
  293                 GLM_FUNC_DECL tvec4<T, P> & operator-=(U scalar);
 
  294                 template <
typename U>
 
  295                 GLM_FUNC_DECL tvec4<T, P> & operator-=(tvec1<U, P> 
const & v);
 
  296                 template <
typename U>
 
  297                 GLM_FUNC_DECL tvec4<T, P> & operator-=(tvec4<U, P> 
const & v);
 
  298                 template <
typename U>
 
  299                 GLM_FUNC_DECL tvec4<T, P> & operator*=(U scalar);
 
  300                 template <
typename U>
 
  301                 GLM_FUNC_DECL tvec4<T, P> & operator*=(tvec1<U, P> 
const & v);
 
  302                 template <
typename U>
 
  303                 GLM_FUNC_DECL tvec4<T, P> & operator*=(tvec4<U, P> 
const & v);
 
  304                 template <
typename U>
 
  305                 GLM_FUNC_DECL tvec4<T, P> & operator/=(U scalar);
 
  306                 template <
typename U>
 
  307                 GLM_FUNC_DECL tvec4<T, P> & operator/=(tvec1<U, P> 
const & v);
 
  308                 template <
typename U>
 
  309                 GLM_FUNC_DECL tvec4<T, P> & operator/=(tvec4<U, P> 
const & v);
 
  314                 GLM_FUNC_DECL tvec4<T, P> & operator++();
 
  315                 GLM_FUNC_DECL tvec4<T, P> & operator--();
 
  316                 GLM_FUNC_DECL tvec4<T, P> operator++(
int);
 
  317                 GLM_FUNC_DECL tvec4<T, P> operator--(
int);
 
  322                 template <
typename U>
 
  323                 GLM_FUNC_DECL tvec4<T, P> & operator%=(U scalar);
 
  324                 template <
typename U>
 
  325                 GLM_FUNC_DECL tvec4<T, P> & operator%=(tvec1<U, P> 
const & v);
 
  326                 template <
typename U>
 
  327                 GLM_FUNC_DECL tvec4<T, P> & operator%=(tvec4<U, P> 
const & v);
 
  328                 template <
typename U>
 
  329                 GLM_FUNC_DECL tvec4<T, P> & operator&=(U scalar);
 
  330                 template <
typename U>
 
  331                 GLM_FUNC_DECL tvec4<T, P> & operator&=(tvec1<U, P> 
const & v);
 
  332                 template <
typename U>
 
  333                 GLM_FUNC_DECL tvec4<T, P> & operator&=(tvec4<U, P> 
const & v);
 
  334                 template <
typename U>
 
  335                 GLM_FUNC_DECL tvec4<T, P> & operator|=(U scalar);
 
  336                 template <
typename U>
 
  337                 GLM_FUNC_DECL tvec4<T, P> & operator|=(tvec1<U, P> 
const & v);
 
  338                 template <
typename U>
 
  339                 GLM_FUNC_DECL tvec4<T, P> & operator|=(tvec4<U, P> 
const & v);
 
  340                 template <
typename U>
 
  341                 GLM_FUNC_DECL tvec4<T, P> & operator^=(U scalar);
 
  342                 template <
typename U>
 
  343                 GLM_FUNC_DECL tvec4<T, P> & operator^=(tvec1<U, P> 
const & v);
 
  344                 template <
typename U>
 
  345                 GLM_FUNC_DECL tvec4<T, P> & operator^=(tvec4<U, P> 
const & v);
 
  346                 template <
typename U>
 
  347                 GLM_FUNC_DECL tvec4<T, P> & operator<<=(U scalar);
 
  348                 template <
typename U>
 
  349                 GLM_FUNC_DECL tvec4<T, P> & operator<<=(tvec1<U, P> 
const & v);
 
  350                 template <
typename U>
 
  351                 GLM_FUNC_DECL tvec4<T, P> & operator<<=(tvec4<U, P> 
const & v);
 
  352                 template <
typename U>
 
  353                 GLM_FUNC_DECL tvec4<T, P> & operator>>=(U scalar);
 
  354                 template <
typename U>
 
  355                 GLM_FUNC_DECL tvec4<T, P> & operator>>=(tvec1<U, P> 
const & v);
 
  356                 template <
typename U>
 
  357                 GLM_FUNC_DECL tvec4<T, P> & operator>>=(tvec4<U, P> 
const & v);
 
  360         template <
typename T, precision P>
 
  361         GLM_FUNC_DECL tvec4<T, P> operator+(tvec4<T, P> 
const & v, T scalar);
 
  363         template <
typename T, precision P>
 
  364         GLM_FUNC_DECL tvec4<T, P> operator+(tvec4<T, P> 
const & v, tvec1<T, P> 
const & s);
 
  366         template <
typename T, precision P>
 
  367         GLM_FUNC_DECL tvec4<T, P> operator+(T scalar, tvec4<T, P> 
const & v);
 
  369         template <
typename T, precision P>
 
  370         GLM_FUNC_DECL tvec4<T, P> operator+(tvec1<T, P> 
const & s, tvec4<T, P> 
const & v);
 
  372         template <
typename T, precision P>
 
  373         GLM_FUNC_DECL tvec4<T, P> operator+(tvec4<T, P> 
const & v1, tvec4<T, P> 
const & v2);
 
  375         template <
typename T, precision P>
 
  376         GLM_FUNC_DECL tvec4<T, P> operator-(tvec4<T, P> 
const & v, T scalar);
 
  378         template <
typename T, precision P>
 
  379         GLM_FUNC_DECL tvec4<T, P> operator-(tvec4<T, P> 
const & v, tvec1<T, P> 
const & s);
 
  381         template <
typename T, precision P>
 
  382         GLM_FUNC_DECL tvec4<T, P> operator-(T scalar, tvec4<T, P> 
const & v);
 
  384         template <
typename T, precision P>
 
  385         GLM_FUNC_DECL tvec4<T, P> operator-(tvec1<T, P> 
const & s, tvec4<T, P> 
const & v);
 
  387         template <
typename T, precision P>
 
  388         GLM_FUNC_DECL tvec4<T, P> operator-(tvec4<T, P> 
const & v1, tvec4<T, P> 
const & v2);
 
  390         template <
typename T, precision P>
 
  391         GLM_FUNC_DECL tvec4<T, P> operator*(tvec4<T, P> 
const & v, T scalar);
 
  393         template <
typename T, precision P>
 
  394         GLM_FUNC_DECL tvec4<T, P> operator*(tvec4<T, P> 
const & v, tvec1<T, P> 
const & s);
 
  396         template <
typename T, precision P>
 
  397         GLM_FUNC_DECL tvec4<T, P> operator*(T scalar, tvec4<T, P> 
const & v);
 
  399         template <
typename T, precision P>
 
  400         GLM_FUNC_DECL tvec4<T, P> operator*(tvec1<T, P> 
const & s, tvec4<T, P> 
const & v);
 
  402         template <
typename T, precision P>
 
  403         GLM_FUNC_DECL tvec4<T, P> operator*(tvec4<T, P> 
const & v1, tvec4<T, P> 
const & v2);
 
  405         template <
typename T, precision P>
 
  406         GLM_FUNC_DECL tvec4<T, P> operator/(tvec4<T, P> 
const & v, T scalar);
 
  408         template <
typename T, precision P>
 
  409         GLM_FUNC_DECL tvec4<T, P> operator/(tvec4<T, P> 
const & v, tvec1<T, P> 
const & s);
 
  411         template <
typename T, precision P>
 
  412         GLM_FUNC_DECL tvec4<T, P> operator/(T scalar, tvec4<T, P> 
const & v);
 
  414         template <
typename T, precision P>
 
  415         GLM_FUNC_DECL tvec4<T, P> operator/(tvec1<T, P> 
const & s, tvec4<T, P> 
const & v);
 
  417         template <
typename T, precision P>
 
  418         GLM_FUNC_DECL tvec4<T, P> operator/(tvec4<T, P> 
const & v1, tvec4<T, P> 
const & v2);
 
  420         template <
typename T, precision P>
 
  421         GLM_FUNC_DECL tvec4<T, P> operator-(tvec4<T, P> 
const & v);
 
  423         template <
typename T, precision P>
 
  424         GLM_FUNC_DECL 
bool operator==(tvec4<T, P> 
const & v1, tvec4<T, P> 
const & v2);
 
  426         template <
typename T, precision P>
 
  427         GLM_FUNC_DECL 
bool operator!=(tvec4<T, P> 
const & v1, tvec4<T, P> 
const & v2);
 
  429         template <
typename T, precision P>
 
  430         GLM_FUNC_DECL tvec4<T, P> operator%(tvec4<T, P> 
const & v, T scalar);
 
  432         template <
typename T, precision P>
 
  433         GLM_FUNC_DECL tvec4<T, P> operator%(tvec4<T, P> 
const & v, tvec1<T, P> 
const & s);
 
  435         template <
typename T, precision P>
 
  436         GLM_FUNC_DECL tvec4<T, P> operator%(T scalar, tvec4<T, P> 
const & v);
 
  438         template <
typename T, precision P>
 
  439         GLM_FUNC_DECL tvec4<T, P> operator%(tvec1<T, P> 
const & s, tvec4<T, P> 
const & v);
 
  441         template <
typename T, precision P>
 
  442         GLM_FUNC_DECL tvec4<T, P> operator%(tvec4<T, P> 
const & v1, tvec4<T, P> 
const & v2);
 
  444         template <
typename T, precision P>
 
  445         GLM_FUNC_DECL tvec4<T, P> operator&(tvec4<T, P> 
const & v, T scalar);
 
  447         template <
typename T, precision P>
 
  448         GLM_FUNC_DECL tvec4<T, P> operator&(tvec4<T, P> 
const & v, tvec1<T, P> 
const & s);
 
  450         template <
typename T, precision P>
 
  451         GLM_FUNC_DECL tvec4<T, P> operator&(T scalar, tvec4<T, P> 
const & v);
 
  453         template <
typename T, precision P>
 
  454         GLM_FUNC_DECL tvec4<T, P> operator&(tvec1<T, P> 
const & s, tvec4<T, P> 
const & v);
 
  456         template <
typename T, precision P>
 
  457         GLM_FUNC_DECL tvec4<T, P> operator&(tvec4<T, P> 
const & v1, tvec4<T, P> 
const & v2);
 
  459         template <
typename T, precision P>
 
  460         GLM_FUNC_DECL tvec4<T, P> operator|(tvec4<T, P> 
const & v, T scalar);
 
  462         template <
typename T, precision P>
 
  463         GLM_FUNC_DECL tvec4<T, P> operator|(tvec4<T, P> 
const & v, tvec1<T, P> 
const & s);
 
  465         template <
typename T, precision P>
 
  466         GLM_FUNC_DECL tvec4<T, P> operator|(T scalar, tvec4<T, P> 
const & v);
 
  468         template <
typename T, precision P>
 
  469         GLM_FUNC_DECL tvec4<T, P> operator|(tvec1<T, P> 
const & s, tvec4<T, P> 
const & v);
 
  471         template <
typename T, precision P>
 
  472         GLM_FUNC_DECL tvec4<T, P> operator|(tvec4<T, P> 
const & v1, tvec4<T, P> 
const & v2);
 
  474         template <
typename T, precision P>
 
  475         GLM_FUNC_DECL tvec4<T, P> operator^(tvec4<T, P> 
const & v, T scalar);
 
  477         template <
typename T, precision P>
 
  478         GLM_FUNC_DECL tvec4<T, P> operator^(tvec4<T, P> 
const & v, tvec1<T, P> 
const & s);
 
  480         template <
typename T, precision P>
 
  481         GLM_FUNC_DECL tvec4<T, P> operator^(T scalar, tvec4<T, P> 
const & v);
 
  483         template <
typename T, precision P>
 
  484         GLM_FUNC_DECL tvec4<T, P> operator^(tvec1<T, P> 
const & s, tvec4<T, P> 
const & v);
 
  486         template <
typename T, precision P>
 
  487         GLM_FUNC_DECL tvec4<T, P> operator^(tvec4<T, P> 
const & v1, tvec4<T, P> 
const & v2);
 
  489         template <
typename T, precision P>
 
  490         GLM_FUNC_DECL tvec4<T, P> operator<<(tvec4<T, P> 
const & v, T scalar);
 
  492         template <
typename T, precision P>
 
  493         GLM_FUNC_DECL tvec4<T, P> operator<<(tvec4<T, P> 
const & v, tvec1<T, P> 
const & s);
 
  495         template <
typename T, precision P>
 
  496         GLM_FUNC_DECL tvec4<T, P> operator<<(T scalar, tvec4<T, P> 
const & v);
 
  498         template <
typename T, precision P>
 
  499         GLM_FUNC_DECL tvec4<T, P> operator<<(tvec1<T, P> 
const & s, tvec4<T, P> 
const & v);
 
  501         template <
typename T, precision P>
 
  502         GLM_FUNC_DECL tvec4<T, P> operator<<(tvec4<T, P> 
const & v1, tvec4<T, P> 
const & v2);
 
  504         template <
typename T, precision P>
 
  505         GLM_FUNC_DECL tvec4<T, P> operator>>(tvec4<T, P> 
const & v, T scalar);
 
  507         template <
typename T, precision P>
 
  508         GLM_FUNC_DECL tvec4<T, P> operator>>(tvec4<T, P> 
const & v, tvec1<T, P> 
const & s);
 
  510         template <
typename T, precision P>
 
  511         GLM_FUNC_DECL tvec4<T, P> operator>>(T scalar, tvec4<T, P> 
const & v);
 
  513         template <
typename T, precision P>
 
  514         GLM_FUNC_DECL tvec4<T, P> operator>>(tvec1<T, P> 
const & s, tvec4<T, P> 
const & v);
 
  516         template <
typename T, precision P>
 
  517         GLM_FUNC_DECL tvec4<T, P> operator>>(tvec4<T, P> 
const & v1, tvec4<T, P> 
const & v2);
 
  519         template <
typename T, precision P> 
 
  520         GLM_FUNC_DECL tvec4<T, P> operator~(tvec4<T, P> 
const & v);
 
  523 #ifndef GLM_EXTERNAL_TEMPLATE 
  524 #include "type_vec4.inl" 
  525 #endif//GLM_EXTERNAL_TEMPLATE 
OpenGL Mathematics (glm.g-truc.net) 
GLM_FUNC_DECL T length(vecType< T, P > const &x)
Returns the length of x, i.e., sqrt(x * x). 
OpenGL Mathematics (glm.g-truc.net) 
OpenGL Mathematics (glm.g-truc.net) 
OpenGL Mathematics (glm.g-truc.net)