8 #include "compute_vector_relational.hpp"
13 template<
typename T, std::
size_t size,
bool aligned>
21 #define GLM_ALIGNED_STORAGE_TYPE_STRUCT(x) \
22 template<typename T> \
23 struct storage<T, x, true> { \
24 GLM_ALIGNED_STRUCT(x) type { \
29 GLM_ALIGNED_STORAGE_TYPE_STRUCT(1)
30 GLM_ALIGNED_STORAGE_TYPE_STRUCT(2)
31 GLM_ALIGNED_STORAGE_TYPE_STRUCT(4)
32 GLM_ALIGNED_STORAGE_TYPE_STRUCT(8)
33 GLM_ALIGNED_STORAGE_TYPE_STRUCT(16)
34 GLM_ALIGNED_STORAGE_TYPE_STRUCT(32)
35 GLM_ALIGNED_STORAGE_TYPE_STRUCT(64)
37 # if GLM_ARCH & GLM_ARCH_SSE2_BIT
39 struct storage<float, 16, true>
41 typedef glm_vec4 type;
45 struct storage<int, 16, true>
47 typedef glm_ivec4 type;
51 struct storage<unsigned int, 16, true>
53 typedef glm_uvec4 type;
82 # if (GLM_ARCH & GLM_ARCH_AVX_BIT)
84 struct storage<double, 32, true>
86 typedef glm_dvec4 type;
90 # if (GLM_ARCH & GLM_ARCH_AVX2_BIT)
92 struct storage<int64, 32, true>
94 typedef glm_i64vec4 type;
98 struct storage<uint64, 32, true>
100 typedef glm_u64vec4 type;
105 #if GLM_HAS_TEMPLATE_ALIASES
106 template <
typename T, qualifier Q = defaultp>
using tvec1 = vec<1, T, Q>;
107 template <
typename T, qualifier Q = defaultp>
using tvec2 = vec<2, T, Q>;
108 template <
typename T, qualifier Q = defaultp>
using tvec3 = vec<3, T, Q>;
109 template <
typename T, qualifier Q = defaultp>
using tvec4 = vec<4, T, Q>;
110 #endif//GLM_HAS_TEMPLATE_ALIASES
112 typedef vec<1, float, highp> highp_vec1_t;
113 typedef vec<1, float, mediump> mediump_vec1_t;
114 typedef vec<1, float, lowp> lowp_vec1_t;
115 typedef vec<1, double, highp> highp_dvec1_t;
116 typedef vec<1, double, mediump> mediump_dvec1_t;
117 typedef vec<1, double, lowp> lowp_dvec1_t;
118 typedef vec<1, int, highp> highp_ivec1_t;
119 typedef vec<1, int, mediump> mediump_ivec1_t;
120 typedef vec<1, int, lowp> lowp_ivec1_t;
121 typedef vec<1, uint, highp> highp_uvec1_t;
122 typedef vec<1, uint, mediump> mediump_uvec1_t;
123 typedef vec<1, uint, lowp> lowp_uvec1_t;
124 typedef vec<1, bool, highp> highp_bvec1_t;
125 typedef vec<1, bool, mediump> mediump_bvec1_t;
126 typedef vec<1, bool, lowp> lowp_bvec1_t;
445 #if(defined(GLM_PRECISION_LOWP_FLOAT))
446 typedef lowp_vec2
vec2;
447 typedef lowp_vec3
vec3;
448 typedef lowp_vec4
vec4;
449 #elif(defined(GLM_PRECISION_MEDIUMP_FLOAT))
450 typedef mediump_vec2
vec2;
451 typedef mediump_vec3
vec3;
452 typedef mediump_vec4
vec4;
453 #else //defined(GLM_PRECISION_HIGHP_FLOAT)
454 typedef highp_vec2
vec2;
468 #endif//GLM_PRECISION
472 #if(defined(GLM_PRECISION_LOWP_DOUBLE))
473 typedef lowp_dvec2
dvec2;
474 typedef lowp_dvec3
dvec3;
475 typedef lowp_dvec4
dvec4;
476 #elif(defined(GLM_PRECISION_MEDIUMP_DOUBLE))
477 typedef mediump_dvec2
dvec2;
478 typedef mediump_dvec3
dvec3;
479 typedef mediump_dvec4
dvec4;
480 #else //defined(GLM_PRECISION_HIGHP_DOUBLE)
481 typedef highp_dvec2
dvec2;
495 #endif//GLM_PRECISION
499 #if(defined(GLM_PRECISION_LOWP_INT))
500 typedef lowp_ivec2
ivec2;
501 typedef lowp_ivec3
ivec3;
502 typedef lowp_ivec4
ivec4;
503 #elif(defined(GLM_PRECISION_MEDIUMP_INT))
504 typedef mediump_ivec2
ivec2;
505 typedef mediump_ivec3
ivec3;
506 typedef mediump_ivec4
ivec4;
507 #else //defined(GLM_PRECISION_HIGHP_INT)
508 typedef highp_ivec2
ivec2;
522 #endif//GLM_PRECISION
526 #if(defined(GLM_PRECISION_LOWP_UINT))
527 typedef lowp_uvec2
uvec2;
528 typedef lowp_uvec3
uvec3;
529 typedef lowp_uvec4
uvec4;
530 #elif(defined(GLM_PRECISION_MEDIUMP_UINT))
531 typedef mediump_uvec2
uvec2;
532 typedef mediump_uvec3
uvec3;
533 typedef mediump_uvec4
uvec4;
534 #else //defined(GLM_PRECISION_HIGHP_UINT)
535 typedef highp_uvec2
uvec2;
549 #endif//GLM_PRECISION
553 #if(defined(GLM_PRECISION_LOWP_BOOL))
554 typedef lowp_bvec2
bvec2;
555 typedef lowp_bvec3
bvec3;
556 typedef lowp_bvec4
bvec4;
557 #elif(defined(GLM_PRECISION_MEDIUMP_BOOL))
558 typedef mediump_bvec2
bvec2;
559 typedef mediump_bvec3
bvec3;
560 typedef mediump_bvec4
bvec4;
561 #else //defined(GLM_PRECISION_HIGHP_BOOL)
562 typedef highp_bvec2
bvec2;
576 #endif//GLM_PRECISION
vec< 3, int, highp > highp_ivec3
3 components vector of high qualifier signed integer numbers.
highp_ivec4 ivec4
4 components vector of signed integer numbers.
vec< 4, double, lowp > lowp_dvec4
4 components vector of low double-qualifier floating-point numbers.
vec< 4, float, mediump > mediump_vec4
4 components vector of medium single-qualifier floating-point numbers.
vec< 4, int, lowp > lowp_ivec4
4 components vector of low qualifier signed integer numbers.
highp_ivec3 ivec3
3 components vector of signed integer numbers.
highp_bvec4 bvec4
4 components vector of boolean.
vec< 4, bool, lowp > lowp_bvec4
4 components vector of low qualifier bool numbers.
vec< 4, int, mediump > mediump_ivec4
4 components vector of medium qualifier signed integer numbers.
vec< 2, uint, highp > highp_uvec2
2 components vector of high qualifier unsigned integer numbers.
vec< 3, uint, lowp > lowp_uvec3
3 components vector of low qualifier unsigned integer numbers.
vec< 3, uint, highp > highp_uvec3
3 components vector of high qualifier unsigned integer numbers.
vec< 3, double, lowp > lowp_dvec3
3 components vector of low double-qualifier floating-point numbers.
highp_vec2 vec2
2 components vector of floating-point numbers.
vec< 2, bool, highp > highp_bvec2
2 components vector of high qualifier bool numbers.
vec< 3, bool, mediump > mediump_bvec3
3 components vector of medium qualifier bool numbers.
vec< 4, int, highp > highp_ivec4
4 components vector of high qualifier signed integer numbers.
vec< 4, float, highp > highp_vec4
4 components vector of high single-qualifier floating-point numbers.
vec< 4, bool, highp > highp_bvec4
4 components vector of high qualifier bool numbers.
vec< 3, int, lowp > lowp_ivec3
3 components vector of low qualifier signed integer numbers.
vec< 2, uint, lowp > lowp_uvec2
2 components vector of low qualifier unsigned integer numbers.
vec< 3, double, mediump > mediump_dvec3
3 components vector of medium double-qualifier floating-point numbers.
vec< 2, double, lowp > lowp_dvec2
2 components vector of low double-qualifier floating-point numbers.
vec< 2, int, lowp > lowp_ivec2
2 components vector of low qualifier signed integer numbers.
vec< 2, double, highp > highp_dvec2
2 components vector of high double-qualifier floating-point numbers.
vec< 4, bool, mediump > mediump_bvec4
4 components vector of medium qualifier bool numbers.
highp_vec4 vec4
4 components vector of floating-point numbers.
vec< 3, double, highp > highp_dvec3
3 components vector of high double-qualifier floating-point numbers.
vec< 2, bool, mediump > mediump_bvec2
2 components vector of medium qualifier bool numbers.
vec< 2, float, lowp > lowp_vec2
2 components vector of low single-qualifier floating-point numbers.
vec< 3, float, lowp > lowp_vec3
3 components vector of low single-qualifier floating-point numbers.
vec< 2, bool, lowp > lowp_bvec2
2 components vector of low qualifier bool numbers.
highp_dvec3 dvec3
3 components vector of double-qualifier floating-point numbers.
vec< 4, double, highp > highp_dvec4
4 components vector of high double-qualifier floating-point numbers.
vec< 2, double, mediump > mediump_dvec2
2 components vector of medium double-qualifier floating-point numbers.
vec< 3, int, mediump > mediump_ivec3
3 components vector of medium qualifier signed integer numbers.
vec< 3, float, highp > highp_vec3
3 components vector of high single-qualifier floating-point numbers.
vec< 4, uint, highp > highp_uvec4
4 components vector of high qualifier unsigned integer numbers.
highp_uvec3 uvec3
3 components vector of unsigned integer numbers.
vec< 2, float, mediump > mediump_vec2
2 components vector of medium single-qualifier floating-point numbers.
highp_vec3 vec3
3 components vector of floating-point numbers.
highp_dvec2 dvec2
2 components vector of double-qualifier floating-point numbers.
vec< 4, float, lowp > lowp_vec4
4 components vector of low single-qualifier floating-point numbers.
highp_bvec2 bvec2
2 components vector of boolean.
vec< 3, float, mediump > mediump_vec3
3 components vector of medium single-qualifier floating-point numbers.
vec< 2, int, mediump > mediump_ivec2
2 components vector of medium qualifier signed integer numbers.
highp_uvec4 uvec4
4 components vector of unsigned integer numbers.
vec< 4, double, mediump > mediump_dvec4
4 components vector of medium double-qualifier floating-point numbers.
highp_uvec2 uvec2
2 components vector of unsigned integer numbers.
vec< 3, uint, mediump > mediump_uvec3
3 components vector of medium qualifier unsigned integer numbers.
vec< 3, bool, highp > highp_bvec3
3 components vector of high qualifier bool numbers.
highp_dvec4 dvec4
4 components vector of double-qualifier floating-point numbers.
vec< 4, uint, lowp > lowp_uvec4
4 components vector of low qualifier unsigned integer numbers.
vec< 3, bool, lowp > lowp_bvec3
3 components vector of low qualifier bool numbers.
vec< 2, float, highp > highp_vec2
2 components vector of high single-qualifier floating-point numbers.
vec< 4, uint, mediump > mediump_uvec4
4 components vector of medium qualifier unsigned integer numbers.
highp_bvec3 bvec3
3 components vector of boolean.
vec< 2, int, highp > highp_ivec2
2 components vector of high qualifier signed integer numbers.
vec< 2, uint, mediump > mediump_uvec2
2 components vector of medium qualifier unsigned integer numbers.
highp_ivec2 ivec2
2 components vector of signed integer numbers.