0.9.9 API documenation: type_float.hpp Source File

| 0.9.9 API documenation

- Main Page
- Modules
- Files

- File List

type_float.hpp
Go to the documentation of this file.
1
4 #pragma once
5
6 #include "setup.hpp"
7
8 namespace glm{
9 namespace detail
10 {
11 typedef float float32;
12
13 # ifndef GLM_FORCE_SINGLE_ONLY
14 typedef double float64;
15 # endif//GLM_FORCE_SINGLE_ONLY
16 }//namespace detail
17
18 typedef float lowp_float_t;
19 typedef float mediump_float_t;
20 typedef double highp_float_t;
21
24
30 typedef lowp_float_t lowp_float;
31
37 typedef mediump_float_t mediump_float;
38
44 typedef highp_float_t highp_float;
45
46 #if(!defined(GLM_PRECISION_HIGHP_FLOAT) && !defined(GLM_PRECISION_MEDIUMP_FLOAT) && !defined(GLM_PRECISION_LOWP_FLOAT))
47 typedef mediump_float float_t;
48 #elif(defined(GLM_PRECISION_HIGHP_FLOAT) && !defined(GLM_PRECISION_MEDIUMP_FLOAT) && !defined(GLM_PRECISION_LOWP_FLOAT))
49 typedef highp_float float_t;
50 #elif(!defined(GLM_PRECISION_HIGHP_FLOAT) && defined(GLM_PRECISION_MEDIUMP_FLOAT) && !defined(GLM_PRECISION_LOWP_FLOAT))
51 typedef mediump_float float_t;
52 #elif(!defined(GLM_PRECISION_HIGHP_FLOAT) && !defined(GLM_PRECISION_MEDIUMP_FLOAT) && defined(GLM_PRECISION_LOWP_FLOAT))
53 typedef lowp_float float_t;
54 #else
55 # error "GLM error: multiple default precision requested for floating-point types"
56 #endif
57
58 typedef float float32;
59
60 # ifndef GLM_FORCE_SINGLE_ONLY
61 typedef double float64;
62 # endif//GLM_FORCE_SINGLE_ONLY
63
65 // check type sizes
66 #ifndef GLM_STATIC_ASSERT_NULL
67 GLM_STATIC_ASSERT(sizeof(glm::float32) == 4, "float32 size isn't 4 bytes on this platform");
68 # ifndef GLM_FORCE_SINGLE_ONLY
69 GLM_STATIC_ASSERT(sizeof(glm::float64) == 8, "float64 size isn't 8 bytes on this platform");
70 # endif//GLM_FORCE_SINGLE_ONLY
71 #endif//GLM_STATIC_ASSERT_NULL
72
74
75 }//namespace glm
glm::highp_float
highp_float_t highp_float
High qualifier floating-point numbers.
Definition: type_float.hpp:44
glm
Definition: common.hpp:20
glm::mediump_float
mediump_float_t mediump_float
Medium qualifier floating-point numbers.
Definition: type_float.hpp:37
glm::float32
float float32
Default 32 bit single-qualifier floating-point scalar.
Definition: type_float.hpp:58
setup.hpp
Core features
glm::lowp_float
lowp_float_t lowp_float
Low qualifier floating-point numbers.
Definition: type_float.hpp:30
glm::float64
double float64
Default 64 bit double-qualifier floating-point scalar.
Definition: type_float.hpp:61