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 tvec2 = vec<2, T, Q>;
107 template <
typename T, qualifier Q = defaultp>
using tvec3 = vec<3, T, Q>;
108 template <
typename T, qualifier Q = defaultp>
using tvec4 = vec<4, T, Q>;
109 #endif//GLM_HAS_TEMPLATE_ALIASES
428 #if(defined(GLM_PRECISION_LOWP_FLOAT))
429 typedef lowp_vec2
vec2;
430 typedef lowp_vec3
vec3;
431 typedef lowp_vec4
vec4;
432 #elif(defined(GLM_PRECISION_MEDIUMP_FLOAT))
433 typedef mediump_vec2
vec2;
434 typedef mediump_vec3
vec3;
435 typedef mediump_vec4
vec4;
436 #else //defined(GLM_PRECISION_HIGHP_FLOAT)
437 typedef highp_vec2
vec2;
451 #endif//GLM_PRECISION
455 #if(defined(GLM_PRECISION_LOWP_DOUBLE))
456 typedef lowp_dvec2
dvec2;
457 typedef lowp_dvec3
dvec3;
458 typedef lowp_dvec4
dvec4;
459 #elif(defined(GLM_PRECISION_MEDIUMP_DOUBLE))
460 typedef mediump_dvec2
dvec2;
461 typedef mediump_dvec3
dvec3;
462 typedef mediump_dvec4
dvec4;
463 #else //defined(GLM_PRECISION_HIGHP_DOUBLE)
464 typedef highp_dvec2
dvec2;
478 #endif//GLM_PRECISION
482 #if(defined(GLM_PRECISION_LOWP_INT))
483 typedef lowp_ivec2
ivec2;
484 typedef lowp_ivec3
ivec3;
485 typedef lowp_ivec4
ivec4;
486 #elif(defined(GLM_PRECISION_MEDIUMP_INT))
487 typedef mediump_ivec2
ivec2;
488 typedef mediump_ivec3
ivec3;
489 typedef mediump_ivec4
ivec4;
490 #else //defined(GLM_PRECISION_HIGHP_INT)
491 typedef highp_ivec2
ivec2;
505 #endif//GLM_PRECISION
509 #if(defined(GLM_PRECISION_LOWP_UINT))
510 typedef lowp_uvec2
uvec2;
511 typedef lowp_uvec3
uvec3;
512 typedef lowp_uvec4
uvec4;
513 #elif(defined(GLM_PRECISION_MEDIUMP_UINT))
514 typedef mediump_uvec2
uvec2;
515 typedef mediump_uvec3
uvec3;
516 typedef mediump_uvec4
uvec4;
517 #else //defined(GLM_PRECISION_HIGHP_UINT)
518 typedef highp_uvec2
uvec2;
532 #endif//GLM_PRECISION
536 #if(defined(GLM_PRECISION_LOWP_BOOL))
537 typedef lowp_bvec2
bvec2;
538 typedef lowp_bvec3
bvec3;
539 typedef lowp_bvec4
bvec4;
540 #elif(defined(GLM_PRECISION_MEDIUMP_BOOL))
541 typedef mediump_bvec2
bvec2;
542 typedef mediump_bvec3
bvec3;
543 typedef mediump_bvec4
bvec4;
544 #else //defined(GLM_PRECISION_HIGHP_BOOL)
545 typedef highp_bvec2
bvec2;
559 #endif//GLM_PRECISION
vec< 4, bool, lowp > lowp_bvec4
4 components vector of low qualifier bool numbers.
vec< 2, int, highp > highp_ivec2
2 components vector of high qualifier signed integer numbers.
vec< 3, int, highp > highp_ivec3
3 components vector of high qualifier signed integer numbers.
vec< 3, uint, lowp > lowp_uvec3
3 components vector of low qualifier unsigned integer numbers.
highp_ivec3 ivec3
3 components vector of signed integer numbers.
vec< 3, bool, lowp > lowp_bvec3
3 components vector of low qualifier bool numbers.
vec< 2, int, mediump > mediump_ivec2
2 components vector of medium qualifier signed integer numbers.
highp_bvec2 bvec2
2 components vector of boolean.
vec< 4, float, lowp > lowp_vec4
4 components vector of low single-qualifier floating-point numbers.
highp_vec2 vec2
2 components vector of floating-point numbers.
vec< 4, double, highp > highp_dvec4
4 components vector of high double-qualifier floating-point numbers.
vec< 2, double, highp > highp_dvec2
2 components vector of high double-qualifier floating-point numbers.
highp_uvec2 uvec2
2 components vector of unsigned integer numbers.
vec< 2, double, mediump > mediump_dvec2
2 components vector of medium double-qualifier floating-point numbers.
highp_dvec4 dvec4
4 components vector of double-qualifier floating-point numbers.
vec< 3, int, mediump > mediump_ivec3
3 components vector of medium qualifier signed integer numbers.
vec< 4, float, mediump > mediump_vec4
4 components vector of medium single-qualifier floating-point numbers.
highp_ivec2 ivec2
2 components vector of signed integer numbers.
vec< 4, bool, highp > highp_bvec4
4 components vector of high qualifier bool numbers.
vec< 4, double, lowp > lowp_dvec4
4 components vector of low double-qualifier floating-point numbers.
vec< 2, double, lowp > lowp_dvec2
2 components vector of low double-qualifier floating-point numbers.
vec< 3, bool, mediump > mediump_bvec3
3 components vector of medium qualifier bool numbers.
vec< 4, double, mediump > mediump_dvec4
4 components vector of medium double-qualifier floating-point numbers.
highp_ivec4 ivec4
4 components vector of signed integer numbers.
vec< 2, float, highp > highp_vec2
2 components vector of high single-qualifier floating-point numbers.
vec< 3, uint, mediump > mediump_uvec3
3 components vector of medium qualifier unsigned integer numbers.
highp_vec4 vec4
4 components vector of floating-point numbers.
highp_uvec4 uvec4
4 components vector of unsigned integer numbers.
vec< 2, bool, mediump > mediump_bvec2
2 components vector of medium qualifier bool numbers.
vec< 4, int, lowp > lowp_ivec4
4 components vector of low qualifier signed integer numbers.
vec< 2, bool, lowp > lowp_bvec2
2 components vector of low qualifier bool numbers.
vec< 3, uint, highp > highp_uvec3
3 components vector of high qualifier 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_bvec3 bvec3
3 components vector of boolean.
vec< 3, int, lowp > lowp_ivec3
3 components vector of low qualifier signed integer numbers.
vec< 4, uint, highp > highp_uvec4
4 components vector of high qualifier unsigned integer numbers.
vec< 4, uint, lowp > lowp_uvec4
4 components vector of low qualifier unsigned integer numbers.
vec< 4, bool, mediump > mediump_bvec4
4 components vector of medium qualifier bool numbers.
highp_bvec4 bvec4
4 components vector of boolean.
vec< 4, int, mediump > mediump_ivec4
4 components vector of medium qualifier signed integer numbers.
highp_dvec2 dvec2
2 components vector of double-qualifier floating-point numbers.
vec< 4, float, highp > highp_vec4
4 components vector of high single-qualifier floating-point numbers.
vec< 2, uint, mediump > mediump_uvec2
2 components vector of medium qualifier unsigned integer numbers.
vec< 4, uint, mediump > mediump_uvec4
4 components vector of medium qualifier unsigned integer numbers.
vec< 2, bool, highp > highp_bvec2
2 components vector of high qualifier bool numbers.
vec< 3, double, highp > highp_dvec3
3 components vector of high double-qualifier floating-point numbers.
vec< 2, uint, highp > highp_uvec2
2 components vector of high qualifier unsigned integer numbers.
vec< 3, double, mediump > mediump_dvec3
3 components vector of medium double-qualifier floating-point numbers.
vec< 4, int, highp > highp_ivec4
4 components vector of high qualifier signed integer numbers.
highp_uvec3 uvec3
3 components vector of unsigned integer numbers.
vec< 3, bool, highp > highp_bvec3
3 components vector of high qualifier bool numbers.
vec< 2, int, lowp > lowp_ivec2
2 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, lowp > lowp_dvec3
3 components vector of low double-qualifier floating-point numbers.
vec< 3, float, mediump > mediump_vec3
3 components vector of medium single-qualifier floating-point numbers.
vec< 3, float, highp > highp_vec3
3 components vector of high single-qualifier floating-point 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.
highp_dvec3 dvec3
3 components vector of double-qualifier floating-point numbers.