Documentation de SFML 2.4.2

Attention: cette page se réfère à une ancienne version de SFML. Cliquez ici pour passer à la dernière version.
Glsl.hpp
1 //
3 // SFML - Simple and Fast Multimedia Library
4 // Copyright (C) 2007-2017 Laurent Gomila (laurent@sfml-dev.org)
5 //
6 // This software is provided 'as-is', without any express or implied warranty.
7 // In no event will the authors be held liable for any damages arising from the use of this software.
8 //
9 // Permission is granted to anyone to use this software for any purpose,
10 // including commercial applications, and to alter it and redistribute it freely,
11 // subject to the following restrictions:
12 //
13 // 1. The origin of this software must not be misrepresented;
14 // you must not claim that you wrote the original software.
15 // If you use this software in a product, an acknowledgment
16 // in the product documentation would be appreciated but is not required.
17 //
18 // 2. Altered source versions must be plainly marked as such,
19 // and must not be misrepresented as being the original software.
20 //
21 // 3. This notice may not be removed or altered from any source distribution.
22 //
24 
25 #ifndef SFML_GLSL_HPP
26 #define SFML_GLSL_HPP
27 
29 // Headers
31 #include <SFML/Graphics/Transform.hpp>
32 #include <SFML/Graphics/Color.hpp>
33 #include <SFML/System/Vector2.hpp>
34 #include <SFML/System/Vector3.hpp>
35 
36 
37 namespace sf
38 {
39 namespace priv
40 {
41  // Forward declarations
42  template <std::size_t Columns, std::size_t Rows>
43  struct Matrix;
44 
45  template <typename T>
46  struct Vector4;
47 
48 #include <SFML/Graphics/Glsl.inl>
49 
50 } // namespace priv
51 
52 
57 namespace Glsl
58 {
59 
65 
71 
77 
83 
89 
95 
96 #ifdef SFML_DOXYGEN
97 
110  typedef implementation-defined Vec4;
111 
124  typedef implementation-defined Ivec4;
125 
130  typedef implementation-defined Bvec4;
131 
155  typedef implementation-defined Mat3;
156 
181  typedef implementation-defined Mat4;
182 
183 #else // SFML_DOXYGEN
184 
185  typedef priv::Vector4<float> Vec4;
186  typedef priv::Vector4<int> Ivec4;
187  typedef priv::Vector4<bool> Bvec4;
188  typedef priv::Matrix<3, 3> Mat3;
189  typedef priv::Matrix<4, 4> Mat4;
190 
191 #endif // SFML_DOXYGEN
192 
193 } // namespace Glsl
194 } // namespace sf
195 
196 #endif // SFML_GLSL_HPP
197 
198 
Vector2< int > Ivec2
2D int vector (ivec2 in GLSL)
Definition: Glsl.hpp:70
Vector2< float > Vec2
2D float vector (vec2 in GLSL)
Definition: Glsl.hpp:64
Vector3< float > Vec3
3D float vector (vec3 in GLSL)
Definition: Glsl.hpp:82
Vector3< int > Ivec3
3D int vector (ivec3 in GLSL)
Definition: Glsl.hpp:88
Utility template class for manipulating 3-dimensional vectors.
Definition: Vector3.hpp:37
Vector3< bool > Bvec3
3D bool vector (bvec3 in GLSL)
Definition: Glsl.hpp:94
Vector2< bool > Bvec2
2D bool vector (bvec2 in GLSL)
Definition: Glsl.hpp:76