GLM 0.9.5

- Main Page
- Related Pages
- Modules
- Namespaces
- Files

- File List

type_float.hpp
1
29 #ifndef glm_core_type_float
30 #define glm_core_type_float
31
32 #include "setup.hpp"
33
34 namespace glm{
35 namespace detail
36 {
37 typedef float float32;
38 typedef double float64;
39 }//namespace detail
40
41 typedef float lowp_float_t;
42 typedef float mediump_float_t;
43 typedef double highp_float_t;
44
47
53 typedef lowp_float_t lowp_float;
54
60 typedef mediump_float_t mediump_float;
61
67 typedef highp_float_t highp_float;
68
69 #if(!defined(GLM_PRECISION_HIGHP_FLOAT) && !defined(GLM_PRECISION_MEDIUMP_FLOAT) && !defined(GLM_PRECISION_LOWP_FLOAT))
70 typedef mediump_float float_t;
71 #elif(defined(GLM_PRECISION_HIGHP_FLOAT) && !defined(GLM_PRECISION_MEDIUMP_FLOAT) && !defined(GLM_PRECISION_LOWP_FLOAT))
72 typedef highp_float float_t;
73 #elif(!defined(GLM_PRECISION_HIGHP_FLOAT) && defined(GLM_PRECISION_MEDIUMP_FLOAT) && !defined(GLM_PRECISION_LOWP_FLOAT))
74 typedef mediump_float float_t;
75 #elif(!defined(GLM_PRECISION_HIGHP_FLOAT) && !defined(GLM_PRECISION_MEDIUMP_FLOAT) && defined(GLM_PRECISION_LOWP_FLOAT))
76 typedef lowp_float float_t;
77 #else
78 # error "GLM error: multiple default precision requested for floating-point types"
79 #endif
80
81 typedef float float32;
82 typedef double float64;
83
85 // check type sizes
86 #ifndef GLM_STATIC_ASSERT_NULL
87 GLM_STATIC_ASSERT(sizeof(glm::float32) == 4, "float32 size isn't 4 bytes on this platform");
88 GLM_STATIC_ASSERT(sizeof(glm::float64) == 8, "float64 size isn't 8 bytes on this platform");
89 #endif//GLM_STATIC_ASSERT_NULL
90
92
93 }//namespace glm
94
95 #endif//glm_core_type_float
glm::float32
float float32
Default 32 bit single-precision floating-point scalar.
Definition: type_float.hpp:81
glm::highp_float
highp_float_t highp_float
High precision floating-point numbers.
Definition: type_float.hpp:67
glm::mediump_float
mediump_float_t mediump_float
Medium precision floating-point numbers.
Definition: type_float.hpp:60
glm::lowp_float
lowp_float_t lowp_float
Low precision floating-point numbers.
Definition: type_float.hpp:53
glm::float64
double float64
Default 64 bit double-precision floating-point scalar.
Definition: type_float.hpp:82