2.8 KB、54行 生 Blame 履歴
1/// @ref core
2/// @file glm/ext/vector_double3_precision.hpp
3
4#pragma once
5#include "../detail/type_vec3.hpp"
6
7namespace glm
8{
9 /// @addtogroup core_vector_precision
10 /// @{
11
12 /// 3 components vector of high double-qualifier floating-point numbers.
13 /// There is no guarantee on the actual qualifier.
14 ///
15 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
16 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
17 typedef vec<3, double, highp> highp_dvec3;
18
19 /// 3 components vector of medium double-qualifier floating-point numbers.
20 /// There is no guarantee on the actual qualifier.
21 ///
22 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
23 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
24 typedef vec<3, double, mediump> mediump_dvec3;
25
26 /// 3 components vector of low double-qualifier floating-point numbers.
27 /// There is no guarantee on the actual qualifier.
28 ///
29 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.1.5 Vectors</a>
30 /// @see <a href="http://www.opengl.org/registry/doc/GLSLangSpec.4.20.8.pdf">GLSL 4.20.8 specification, section 4.7.2 Precision Qualifier</a>
31 typedef vec<3, double, lowp> lowp_dvec3;
32
33 /// @}
34}//namespace glm
35
36#if GLM_CONFIG_CTOR_INIT == GLM_DISABLE
37static_assert(std::is_trivially_default_constructible<glm::highp_dvec3>::value);
38static_assert(std::is_trivially_default_constructible<glm::mediump_dvec3>::value);
39static_assert(std::is_trivially_default_constructible<glm::lowp_dvec3>::value);
40#endif
41static_assert(std::is_trivially_copy_assignable<glm::highp_dvec3>::value);
42static_assert(std::is_trivially_copy_assignable<glm::mediump_dvec3>::value);
43static_assert(std::is_trivially_copy_assignable<glm::lowp_dvec3>::value);
44static_assert(std::is_trivially_copyable<glm::highp_dvec3>::value);
45static_assert(std::is_trivially_copyable<glm::mediump_dvec3>::value);
46static_assert(std::is_trivially_copyable<glm::lowp_dvec3>::value);
47static_assert(std::is_copy_constructible<glm::highp_dvec3>::value);
48static_assert(std::is_copy_constructible<glm::mediump_dvec3>::value);
49static_assert(std::is_copy_constructible<glm::lowp_dvec3>::value);
50static_assert(glm::highp_dvec3::length() == 3);
51static_assert(glm::mediump_dvec3::length() == 3);
52static_assert(glm::lowp_dvec3::length() == 3);
53static_assert(sizeof(glm::highp_dvec3) == sizeof(glm::mediump_dvec3));
54static_assert(sizeof(glm::highp_dvec3) == sizeof(glm::lowp_dvec3));