|
template<typename genType > |
GLM_FUNC_DECL GLM_CONSTEXPR genType | identity () |
| Builds an identity matrix.
|
|
template<typename T , qualifier Q> |
GLM_FUNC_DECL mat< 4, 4, T, Q > | lookAt (vec< 3, T, Q > const &eye, vec< 3, T, Q > const ¢er, vec< 3, T, Q > const &up) |
| Build a look at view matrix based on the default handedness. More...
|
|
template<typename T , qualifier Q> |
GLM_FUNC_DECL mat< 4, 4, T, Q > | lookAtLH (vec< 3, T, Q > const &eye, vec< 3, T, Q > const ¢er, vec< 3, T, Q > const &up) |
| Build a left handed look at view matrix. More...
|
|
template<typename T , qualifier Q> |
GLM_FUNC_DECL mat< 4, 4, T, Q > | lookAtRH (vec< 3, T, Q > const &eye, vec< 3, T, Q > const ¢er, vec< 3, T, Q > const &up) |
| Build a right handed look at view matrix. More...
|
|
template<typename T , qualifier Q> |
GLM_FUNC_DECL mat< 4, 4, T, Q > | rotate (mat< 4, 4, T, Q > const &m, T angle, vec< 3, T, Q > const &axis) |
| Builds a rotation 4 * 4 matrix created from an axis vector and an angle. More...
|
|
template<typename T , qualifier Q> |
GLM_FUNC_DECL mat< 4, 4, T, Q > | scale (mat< 4, 4, T, Q > const &m, vec< 3, T, Q > const &v) |
| Builds a scale 4 * 4 matrix created from 3 scalars. More...
|
|
template<typename T , qualifier Q> |
GLM_FUNC_QUALIFIER mat< 4, 4, T, Q > | shear (mat< 4, 4, T, Q > const &m, vec< 3, T, Q > const &p, vec< 2, T, Q > const &l_x, vec< 2, T, Q > const &l_y, vec< 2, T, Q > const &l_z) |
| Builds a scale 4 * 4 matrix created from point referent 3 shearers. More...
|
|
template<typename T , qualifier Q> |
GLM_FUNC_DECL GLM_CONSTEXPR mat< 4, 4, T, Q > | translate (mat< 4, 4, T, Q > const &m, vec< 3, T, Q > const &v) |
| Builds a translation 4 * 4 matrix created from a vector of 3 components. More...
|
|
Defines functions that generate common transformation matrices.
The matrices generated by this extension use standard OpenGL fixed-function conventions. For example, the lookAt function generates a transform from world space into the specific eye space that the projective matrix functions (perspective, ortho, etc) are designed to expect. The OpenGL compatibility specifications defines the particular layout of this eye space.
GLM_FUNC_QUALIFIER mat<4, 4, T, Q> glm::shear |
( |
mat< 4, 4, T, Q > const & |
m, |
|
|
vec< 3, T, Q > const & |
p, |
|
|
vec< 2, T, Q > const & |
l_x, |
|
|
vec< 2, T, Q > const & |
l_y, |
|
|
vec< 2, T, Q > const & |
l_z |
|
) |
| |
Builds a scale 4 * 4 matrix created from point referent 3 shearers.
- Parameters
-
m | Input matrix multiplied by this shear matrix. |
p | Point of shearing as reference. |
l_x | Ratio of matrix.x projection in YZ plane relative to the y-axis/z-axis. |
l_y | Ratio of matrix.y projection in XZ plane relative to the x-axis/z-axis. |
l_z | Ratio of matrix.z projection in XY plane relative to the x-axis/y-axis. |
as example: [1 , l_xy, l_xz, -(l_xy+l_xz) * p_x] [x] T [x, y
, z, w
] = [x, y
, z, w
] * [l_yx, 1 , l_yz, -(l_yx+l_yz) * p_y] [y] [l_zx, l_zy, 1 , -(l_zx+l_zy) * p_z] [z] [0 , 0 , 0 , 1 ] [w]
- Template Parameters
-
T | A floating-point shear type |
Q | A value from qualifier enum |
- See also
- - shear(mat<4, 4, T, Q> const& m, T x, T y, T z)
-
- shear(vec<3, T, Q> const& p)
-
- shear(vec<2, T, Q> const& l_x)
-
- shear(vec<2, T, Q> const& l_y)
-
- shear(vec<2, T, Q> const& l_z)
-
no resource...