7 #if GLM_SWIZZLE == GLM_SWIZZLE_ENABLED 
    8 #       if GLM_HAS_UNRESTRICTED_UNIONS 
   18         template <
typename T, precision P = defaultp>
 
   24                 typedef tvec2<T, P> type;
 
   25                 typedef tvec2<bool, P> bool_type;
 
   29 #               if GLM_HAS_ALIGNED_TYPE 
   30 #                       if GLM_COMPILER & GLM_COMPILER_GCC 
   31 #                               pragma GCC diagnostic push 
   32 #                               pragma GCC diagnostic ignored "-Wpedantic" 
   34 #                       if GLM_COMPILER & GLM_COMPILER_CLANG 
   35 #                               pragma clang diagnostic push 
   36 #                               pragma clang diagnostic ignored "-Wgnu-anonymous-struct" 
   37 #                               pragma clang diagnostic ignored "-Wnested-anon-types" 
   46 #                               if GLM_SWIZZLE == GLM_SWIZZLE_ENABLED 
   47                                         _GLM_SWIZZLE2_2_MEMBERS(T, P, glm::tvec2, x, y)
 
   48                                         _GLM_SWIZZLE2_2_MEMBERS(T, P, 
glm::tvec2, r, g)
 
   49                                         _GLM_SWIZZLE2_2_MEMBERS(T, P, 
glm::tvec2, s, t)
 
   50                                         _GLM_SWIZZLE2_3_MEMBERS(T, P, 
glm::tvec3, x, y)
 
   51                                         _GLM_SWIZZLE2_3_MEMBERS(T, P, 
glm::tvec3, r, g)
 
   52                                         _GLM_SWIZZLE2_3_MEMBERS(T, P, 
glm::tvec3, s, t)
 
   53                                         _GLM_SWIZZLE2_4_MEMBERS(T, P, 
glm::tvec4, x, y)
 
   54                                         _GLM_SWIZZLE2_4_MEMBERS(T, P, 
glm::tvec4, r, g)
 
   55                                         _GLM_SWIZZLE2_4_MEMBERS(T, P, 
glm::tvec4, s, t)
 
   60 #                       if GLM_COMPILER & GLM_COMPILER_CLANG 
   61 #                               pragma clang diagnostic pop 
   63 #                       if GLM_COMPILER & GLM_COMPILER_GCC 
   64 #                               pragma GCC diagnostic pop 
   70 #                       if GLM_SWIZZLE == GLM_SWIZZLE_ENABLED 
   71                                 GLM_SWIZZLE_GEN_VEC_FROM_VEC2(T, P, tvec2, tvec2, tvec3, tvec4)
 
   78                 typedef length_t length_type;
 
   79                 GLM_FUNC_DECL 
static length_type 
length(){
return 2;}
 
   81                 GLM_FUNC_DECL T & operator[](length_type i);
 
   82                 GLM_FUNC_DECL T 
const & operator[](length_type i) 
const;
 
   86                 GLM_FUNC_DECL GLM_CONSTEXPR tvec2() GLM_DEFAULT_CTOR;
 
   87                 GLM_FUNC_DECL GLM_CONSTEXPR tvec2(tvec2<T, P> const& v) GLM_DEFAULT;
 
   88                 template <precision Q>
 
   89                 GLM_FUNC_DECL GLM_CONSTEXPR tvec2(tvec2<T, Q> const& v);
 
   93                 GLM_FUNC_DECL GLM_CONSTEXPR_CTOR explicit tvec2(ctor);
 
   94                 GLM_FUNC_DECL GLM_CONSTEXPR explicit tvec2(T scalar);
 
   95                 GLM_FUNC_DECL GLM_CONSTEXPR tvec2(T s1, T s2);
 
  100                 template <typename A, typename B>
 
  101                 GLM_FUNC_DECL GLM_CONSTEXPR tvec2(A x, B y);
 
  102                 template <typename A, typename B>
 
  103                 GLM_FUNC_DECL GLM_CONSTEXPR tvec2(tvec1<A, P> const & v1, tvec1<B, P> const & v2);
 
  108                 template <typename U, precision Q>
 
  109                 GLM_FUNC_DECL GLM_CONSTEXPR GLM_EXPLICIT tvec2(tvec3<U, Q> const & v);
 
  111                 template <typename U, precision Q>
 
  112                 GLM_FUNC_DECL GLM_CONSTEXPR GLM_EXPLICIT tvec2(tvec4<U, Q> const & v);
 
  115                 template <typename U, precision Q>
 
  116                 GLM_FUNC_DECL GLM_CONSTEXPR GLM_EXPLICIT tvec2(tvec2<U, Q> const & v);
 
  119 #               if GLM_HAS_UNRESTRICTED_UNIONS && (GLM_SWIZZLE == GLM_SWIZZLE_ENABLED) 
  120                         template <
int E0, 
int E1>
 
  121                         GLM_FUNC_DECL tvec2(detail::_swizzle<2, T, P, glm::tvec2, E0, E1,-1,-2> 
const& that)
 
  125 #               endif// GLM_HAS_UNRESTRICTED_UNIONS && (GLM_SWIZZLE == GLM_SWIZZLE_ENABLED) 
  129                 GLM_FUNC_DECL tvec2<T, P>& operator=(tvec2<T, P> 
const & v) GLM_DEFAULT;
 
  131                 template <
typename U>
 
  132                 GLM_FUNC_DECL tvec2<T, P>& operator=(tvec2<U, P> 
const & v);
 
  133                 template <
typename U>
 
  134                 GLM_FUNC_DECL tvec2<T, P>& operator+=(U scalar);
 
  135                 template <
typename U>
 
  136                 GLM_FUNC_DECL tvec2<T, P>& operator+=(tvec1<U, P> 
const & v);
 
  137                 template <
typename U>
 
  138                 GLM_FUNC_DECL tvec2<T, P>& operator+=(tvec2<U, P> 
const & v);
 
  139                 template <
typename U>
 
  140                 GLM_FUNC_DECL tvec2<T, P>& operator-=(U scalar);
 
  141                 template <
typename U>
 
  142                 GLM_FUNC_DECL tvec2<T, P>& operator-=(tvec1<U, P> 
const & v);
 
  143                 template <
typename U>
 
  144                 GLM_FUNC_DECL tvec2<T, P>& operator-=(tvec2<U, P> 
const & v);
 
  145                 template <
typename U>
 
  146                 GLM_FUNC_DECL tvec2<T, P>& operator*=(U scalar);
 
  147                 template <
typename U>
 
  148                 GLM_FUNC_DECL tvec2<T, P>& operator*=(tvec1<U, P> 
const & v);
 
  149                 template <
typename U>
 
  150                 GLM_FUNC_DECL tvec2<T, P>& operator*=(tvec2<U, P> 
const & v);
 
  151                 template <
typename U>
 
  152                 GLM_FUNC_DECL tvec2<T, P>& operator/=(U scalar);
 
  153                 template <
typename U>
 
  154                 GLM_FUNC_DECL tvec2<T, P>& operator/=(tvec1<U, P> 
const & v);
 
  155                 template <
typename U>
 
  156                 GLM_FUNC_DECL tvec2<T, P>& operator/=(tvec2<U, P> 
const & v);
 
  160                 GLM_FUNC_DECL tvec2<T, P> & operator++();
 
  161                 GLM_FUNC_DECL tvec2<T, P> & operator--();
 
  162                 GLM_FUNC_DECL tvec2<T, P> operator++(
int);
 
  163                 GLM_FUNC_DECL tvec2<T, P> operator--(
int);
 
  167                 template <
typename U> 
 
  168                 GLM_FUNC_DECL tvec2<T, P> & operator%=(U scalar);
 
  169                 template <
typename U> 
 
  170                 GLM_FUNC_DECL tvec2<T, P> & operator%=(tvec1<U, P> 
const & v);
 
  171                 template <
typename U> 
 
  172                 GLM_FUNC_DECL tvec2<T, P> & operator%=(tvec2<U, P> 
const & v);
 
  173                 template <
typename U> 
 
  174                 GLM_FUNC_DECL tvec2<T, P> & operator&=(U scalar);
 
  175                 template <
typename U> 
 
  176                 GLM_FUNC_DECL tvec2<T, P> & operator&=(tvec1<U, P> 
const & v);
 
  177                 template <
typename U> 
 
  178                 GLM_FUNC_DECL tvec2<T, P> & operator&=(tvec2<U, P> 
const & v);
 
  179                 template <
typename U> 
 
  180                 GLM_FUNC_DECL tvec2<T, P> & operator|=(U scalar);
 
  181                 template <
typename U> 
 
  182                 GLM_FUNC_DECL tvec2<T, P> & operator|=(tvec1<U, P> 
const & v);
 
  183                 template <
typename U> 
 
  184                 GLM_FUNC_DECL tvec2<T, P> & operator|=(tvec2<U, P> 
const & v);
 
  185                 template <
typename U> 
 
  186                 GLM_FUNC_DECL tvec2<T, P> & operator^=(U scalar);
 
  187                 template <
typename U> 
 
  188                 GLM_FUNC_DECL tvec2<T, P> & operator^=(tvec1<U, P> 
const & v);
 
  189                 template <
typename U> 
 
  190                 GLM_FUNC_DECL tvec2<T, P> & operator^=(tvec2<U, P> 
const & v);
 
  191                 template <
typename U> 
 
  192                 GLM_FUNC_DECL tvec2<T, P> & operator<<=(U scalar);
 
  193                 template <
typename U> 
 
  194                 GLM_FUNC_DECL tvec2<T, P> & operator<<=(tvec1<U, P> 
const & v);
 
  195                 template <
typename U> 
 
  196                 GLM_FUNC_DECL tvec2<T, P> & operator<<=(tvec2<U, P> 
const & v);
 
  197                 template <
typename U> 
 
  198                 GLM_FUNC_DECL tvec2<T, P> & operator>>=(U scalar);
 
  199                 template <
typename U> 
 
  200                 GLM_FUNC_DECL tvec2<T, P> & operator>>=(tvec1<U, P> 
const & v);
 
  201                 template <
typename U> 
 
  202                 GLM_FUNC_DECL tvec2<T, P> & operator>>=(tvec2<U, P> 
const & v);
 
  207         template <
typename T, precision P>
 
  208         GLM_FUNC_DECL tvec2<T, P> operator+(tvec2<T, P> 
const & v);
 
  210         template <
typename T, precision P>
 
  211         GLM_FUNC_DECL tvec2<T, P> operator-(tvec2<T, P> 
const & v);
 
  215         template <
typename T, precision P>
 
  216         GLM_FUNC_DECL tvec2<T, P> operator+(tvec2<T, P> 
const & v, T scalar);
 
  218         template <
typename T, precision P>
 
  219         GLM_FUNC_DECL tvec2<T, P> operator+(tvec2<T, P> 
const & v1, tvec1<T, P> 
const & v2);
 
  221         template <
typename T, precision P>
 
  222         GLM_FUNC_DECL tvec2<T, P> operator+(T scalar, tvec2<T, P> 
const & v);
 
  224         template <
typename T, precision P>
 
  225         GLM_FUNC_DECL tvec2<T, P> operator+(tvec1<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  227         template <
typename T, precision P>
 
  228         GLM_FUNC_DECL tvec2<T, P> operator+(tvec2<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  230         template <
typename T, precision P>
 
  231         GLM_FUNC_DECL tvec2<T, P> operator-(tvec2<T, P> 
const & v, T scalar);
 
  233         template <
typename T, precision P>
 
  234         GLM_FUNC_DECL tvec2<T, P> operator-(tvec2<T, P> 
const & v1, tvec1<T, P> 
const & v2);
 
  236         template <
typename T, precision P>
 
  237         GLM_FUNC_DECL tvec2<T, P> operator-(T scalar, tvec2<T, P> 
const & v);
 
  239         template <
typename T, precision P>
 
  240         GLM_FUNC_DECL tvec2<T, P> operator-(tvec1<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  242         template <
typename T, precision P>
 
  243         GLM_FUNC_DECL tvec2<T, P> operator-(tvec2<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  245         template <
typename T, precision P>
 
  246         GLM_FUNC_DECL tvec2<T, P> operator*(tvec2<T, P> 
const & v, T scalar);
 
  248         template <
typename T, precision P>
 
  249         GLM_FUNC_DECL tvec2<T, P> operator*(tvec2<T, P> 
const & v1, tvec1<T, P> 
const & v2);
 
  251         template <
typename T, precision P>
 
  252         GLM_FUNC_DECL tvec2<T, P> operator*(T scalar, tvec2<T, P> 
const & v);
 
  254         template <
typename T, precision P>
 
  255         GLM_FUNC_DECL tvec2<T, P> operator*(tvec1<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  257         template <
typename T, precision P>
 
  258         GLM_FUNC_DECL tvec2<T, P> operator*(tvec2<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  260         template <
typename T, precision P>
 
  261         GLM_FUNC_DECL tvec2<T, P> operator/(tvec2<T, P> 
const & v, T scalar);
 
  263         template <
typename T, precision P>
 
  264         GLM_FUNC_DECL tvec2<T, P> operator/(tvec2<T, P> 
const & v1, tvec1<T, P> 
const & v2);
 
  266         template <
typename T, precision P>
 
  267         GLM_FUNC_DECL tvec2<T, P> operator/(T scalar, tvec2<T, P> 
const & v);
 
  269         template <
typename T, precision P>
 
  270         GLM_FUNC_DECL tvec2<T, P> operator/(tvec1<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  272         template <
typename T, precision P>
 
  273         GLM_FUNC_DECL tvec2<T, P> operator/(tvec2<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  275         template <
typename T, precision P>
 
  276         GLM_FUNC_DECL tvec2<T, P> operator%(tvec2<T, P> 
const & v, T scalar);
 
  278         template <
typename T, precision P>
 
  279         GLM_FUNC_DECL tvec2<T, P> operator%(tvec2<T, P> 
const & v1, tvec1<T, P> 
const & v2);
 
  281         template <
typename T, precision P>
 
  282         GLM_FUNC_DECL tvec2<T, P> operator%(T scalar, tvec2<T, P> 
const & v);
 
  284         template <
typename T, precision P>
 
  285         GLM_FUNC_DECL tvec2<T, P> operator%(tvec1<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  287         template <
typename T, precision P>
 
  288         GLM_FUNC_DECL tvec2<T, P> operator%(tvec2<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  290         template <
typename T, precision P>
 
  291         GLM_FUNC_DECL tvec2<T, P> operator&(tvec2<T, P> 
const & v, T scalar);
 
  293         template <
typename T, precision P>
 
  294         GLM_FUNC_DECL tvec2<T, P> operator&(tvec2<T, P> 
const & v1, tvec1<T, P> 
const & v2);
 
  296         template <
typename T, precision P>
 
  297         GLM_FUNC_DECL tvec2<T, P> operator&(T scalar, tvec2<T, P> 
const & v);
 
  299         template <
typename T, precision P>
 
  300         GLM_FUNC_DECL tvec2<T, P> operator&(tvec1<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  302         template <
typename T, precision P>
 
  303         GLM_FUNC_DECL tvec2<T, P> operator&(tvec2<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  305         template <
typename T, precision P>
 
  306         GLM_FUNC_DECL tvec2<T, P> operator|(tvec2<T, P> 
const & v, T scalar);
 
  308         template <
typename T, precision P>
 
  309         GLM_FUNC_DECL tvec2<T, P> operator|(tvec2<T, P> 
const & v1, tvec1<T, P> 
const & v2);
 
  311         template <
typename T, precision P>
 
  312         GLM_FUNC_DECL tvec2<T, P> operator|(T scalar, tvec2<T, P> 
const & v);
 
  314         template <
typename T, precision P>
 
  315         GLM_FUNC_DECL tvec2<T, P> operator|(tvec1<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  317         template <
typename T, precision P>
 
  318         GLM_FUNC_DECL tvec2<T, P> operator|(tvec2<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  320         template <
typename T, precision P>
 
  321         GLM_FUNC_DECL tvec2<T, P> operator^(tvec2<T, P> 
const & v, T scalar);
 
  323         template <
typename T, precision P>
 
  324         GLM_FUNC_DECL tvec2<T, P> operator^(tvec2<T, P> 
const & v1, tvec1<T, P> 
const & v2);
 
  326         template <
typename T, precision P>
 
  327         GLM_FUNC_DECL tvec2<T, P> operator^(T scalar, tvec2<T, P> 
const & v);
 
  329         template <
typename T, precision P>
 
  330         GLM_FUNC_DECL tvec2<T, P> operator^(tvec1<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  332         template <
typename T, precision P>
 
  333         GLM_FUNC_DECL tvec2<T, P> operator^(tvec2<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  335         template <
typename T, precision P>
 
  336         GLM_FUNC_DECL tvec2<T, P> operator<<(tvec2<T, P> 
const & v, T scalar);
 
  338         template <
typename T, precision P>
 
  339         GLM_FUNC_DECL tvec2<T, P> operator<<(tvec2<T, P> 
const & v1, tvec1<T, P> 
const & v2);
 
  341         template <
typename T, precision P>
 
  342         GLM_FUNC_DECL tvec2<T, P> operator<<(T scalar, tvec2<T, P> 
const & v);
 
  344         template <
typename T, precision P>
 
  345         GLM_FUNC_DECL tvec2<T, P> operator<<(tvec1<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  347         template <
typename T, precision P>
 
  348         GLM_FUNC_DECL tvec2<T, P> operator<<(tvec2<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  350         template <
typename T, precision P>
 
  351         GLM_FUNC_DECL tvec2<T, P> operator>>(tvec2<T, P> 
const & v, T scalar);
 
  353         template <
typename T, precision P>
 
  354         GLM_FUNC_DECL tvec2<T, P> operator>>(tvec2<T, P> 
const & v1, tvec1<T, P> 
const & v2);
 
  356         template <
typename T, precision P>
 
  357         GLM_FUNC_DECL tvec2<T, P> operator>>(T scalar, tvec2<T, P> 
const & v);
 
  359         template <
typename T, precision P>
 
  360         GLM_FUNC_DECL tvec2<T, P> operator>>(tvec1<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  362         template <
typename T, precision P>
 
  363         GLM_FUNC_DECL tvec2<T, P> operator>>(tvec2<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  365         template <
typename T, precision P>
 
  366         GLM_FUNC_DECL tvec2<T, P> operator~(tvec2<T, P> 
const & v);
 
  370         template <
typename T, precision P>
 
  371         GLM_FUNC_DECL 
bool operator==(tvec2<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  373         template <
typename T, precision P>
 
  374         GLM_FUNC_DECL 
bool operator!=(tvec2<T, P> 
const & v1, tvec2<T, P> 
const & v2);
 
  376         template <precision P>
 
  377         GLM_FUNC_DECL tvec2<bool, P> operator&&(tvec2<bool, P> 
const & v1, tvec2<bool, P> 
const & v2);
 
  379         template <precision P>
 
  380         GLM_FUNC_DECL tvec2<bool, P> operator||(tvec2<bool, P> 
const & v1, tvec2<bool, P> 
const & v2);
 
  383 #ifndef GLM_EXTERNAL_TEMPLATE 
  384 #include "type_vec2.inl" 
  385 #endif//GLM_EXTERNAL_TEMPLATE 
GLM_FUNC_DECL T length(vecType< T, P > const &x)
Returns the length of x, i.e., sqrt(x * x).