| 0.9.9 API documenation

- Main Page
- Modules
- Files

- File List

transform2.hpp
Go to the documentation of this file.
1
14 #pragma once
15
16 // Dependency:
17 #include "../glm.hpp"
18 #include "../gtx/transform.hpp"
19
20 #ifndef GLM_ENABLE_EXPERIMENTAL
21 # error "GLM: GLM_GTX_transform2 is an experimetal extension and may change in the future. Use #define GLM_ENABLE_EXPERIMENTAL before including it, if you really want to use it."
22 #endif
23
24 #if GLM_MESSAGES == GLM_MESSAGES_ENABLED && !defined(GLM_EXT_INCLUDED)
25 # pragma message("GLM: GLM_GTX_transform2 extension included")
26 #endif
27
28 namespace glm
29 {
32
35 template <typename T, precision P>
36 GLM_FUNC_DECL tmat3x3<T, P> shearX2D(
37 tmat3x3<T, P> const & m,
38 T y);
39
42 template <typename T, precision P>
43 GLM_FUNC_DECL tmat3x3<T, P> shearY2D(
44 tmat3x3<T, P> const & m,
45 T x);
46
49 template <typename T, precision P>
50 GLM_FUNC_DECL tmat4x4<T, P> shearX3D(
51 const tmat4x4<T, P> & m,
52 T y,
53 T z);
54
57 template <typename T, precision P>
58 GLM_FUNC_DECL tmat4x4<T, P> shearY3D(
59 const tmat4x4<T, P> & m,
60 T x,
61 T z);
62
65 template <typename T, precision P>
66 GLM_FUNC_DECL tmat4x4<T, P> shearZ3D(
67 const tmat4x4<T, P> & m,
68 T x,
69 T y);
70
71 //template <typename T> GLM_FUNC_QUALIFIER tmat4x4<T, P> shear(const tmat4x4<T, P> & m, shearPlane, planePoint, angle)
72 // Identity + tan(angle) * cross(Normal, OnPlaneVector) 0
73 // - dot(PointOnPlane, normal) * OnPlaneVector 1
74
75 // Reflect functions seem to don't work
76 //template <typename T> tmat3x3<T, P> reflect2D(const tmat3x3<T, P> & m, const tvec3<T, P>& normal){return reflect2DGTX(m, normal);} //!< \brief Build a reflection matrix (from GLM_GTX_transform2 extension)
77 //template <typename T> tmat4x4<T, P> reflect3D(const tmat4x4<T, P> & m, const tvec3<T, P>& normal){return reflect3DGTX(m, normal);} //!< \brief Build a reflection matrix (from GLM_GTX_transform2 extension)
78
81 template <typename T, precision P>
82 GLM_FUNC_DECL tmat3x3<T, P> proj2D(
83 const tmat3x3<T, P> & m,
84 const tvec3<T, P>& normal);
85
88 template <typename T, precision P>
89 GLM_FUNC_DECL tmat4x4<T, P> proj3D(
90 const tmat4x4<T, P> & m,
91 const tvec3<T, P>& normal);
92
95 template <typename valType, precision P>
96 GLM_FUNC_DECL tmat4x4<valType, P> scaleBias(
97 valType scale,
98 valType bias);
99
102 template <typename valType, precision P>
103 GLM_FUNC_DECL tmat4x4<valType, P> scaleBias(
104 tmat4x4<valType, P> const & m,
105 valType scale,
106 valType bias);
107
109 }// namespace glm
110
111 #include "transform2.inl"
glm::scaleBias
GLM_FUNC_DECL tmat4x4< valType, P > scaleBias(tmat4x4< valType, P > const &m, valType scale, valType bias)
Build a scale bias matrix.
glm::proj2D
GLM_FUNC_DECL tmat3x3< T, P > proj2D(const tmat3x3< T, P > &m, const tvec3< T, P > &normal)
Build planar projection matrix along normal axis.
glm::shearY2D
GLM_FUNC_DECL tmat3x3< T, P > shearY2D(tmat3x3< T, P > const &m, T x)
Transforms a matrix with a shearing on Y axis.
glm::shearY3D
GLM_FUNC_DECL tmat4x4< T, P > shearY3D(const tmat4x4< T, P > &m, T x, T z)
Transforms a matrix with a shearing on Y axis.
glm::proj3D
GLM_FUNC_DECL tmat4x4< T, P > proj3D(const tmat4x4< T, P > &m, const tvec3< T, P > &normal)
Build planar projection matrix along normal axis.
glm::shearX3D
GLM_FUNC_DECL tmat4x4< T, P > shearX3D(const tmat4x4< T, P > &m, T y, T z)
Transforms a matrix with a shearing on X axis From GLM_GTX_transform2 extension.
glm::shearX2D
GLM_FUNC_DECL tmat3x3< T, P > shearX2D(tmat3x3< T, P > const &m, T y)
Transforms a matrix with a shearing on X axis.
glm::scale
GLM_FUNC_DECL tmat4x4< T, P > scale(tmat4x4< T, P > const &m, tvec3< T, P > const &v)
Builds a scale 4 * 4 matrix created from 3 scalars.
glm
Definition: _noise.hpp:11
glm::shearZ3D
GLM_FUNC_DECL tmat4x4< T, P > shearZ3D(const tmat4x4< T, P > &m, T x, T y)
Transforms a matrix with a shearing on Z axis.