Fixed GTX_transform2 shear* functions #403

This commit is contained in:
Christophe Riccio 2016-11-01 23:44:03 +01:00
parent 33ea25c052
commit 03672e9428
2 changed files with 9 additions and 8 deletions

View File

@ -7,7 +7,7 @@ namespace glm
GLM_FUNC_QUALIFIER tmat3x3<T, P> shearX2D(tmat3x3<T, P> const& m, T s) GLM_FUNC_QUALIFIER tmat3x3<T, P> shearX2D(tmat3x3<T, P> const& m, T s)
{ {
tmat3x3<T, P> r(1); tmat3x3<T, P> r(1);
r[0][1] = s; r[1][0] = s;
return m * r; return m * r;
} }
@ -15,7 +15,7 @@ namespace glm
GLM_FUNC_QUALIFIER tmat3x3<T, P> shearY2D(tmat3x3<T, P> const& m, T s) GLM_FUNC_QUALIFIER tmat3x3<T, P> shearY2D(tmat3x3<T, P> const& m, T s)
{ {
tmat3x3<T, P> r(1); tmat3x3<T, P> r(1);
r[1][0] = s; r[0][1] = s;
return m * r; return m * r;
} }
@ -23,8 +23,8 @@ namespace glm
GLM_FUNC_QUALIFIER tmat4x4<T, P> shearX3D(tmat4x4<T, P> const& m, T s, T t) GLM_FUNC_QUALIFIER tmat4x4<T, P> shearX3D(tmat4x4<T, P> const& m, T s, T t)
{ {
tmat4x4<T, P> r(1); tmat4x4<T, P> r(1);
r[1][0] = s; r[0][1] = s;
r[2][0] = t; r[0][2] = t;
return m * r; return m * r;
} }
@ -32,8 +32,8 @@ namespace glm
GLM_FUNC_QUALIFIER tmat4x4<T, P> shearY3D(tmat4x4<T, P> const& m, T s, T t) GLM_FUNC_QUALIFIER tmat4x4<T, P> shearY3D(tmat4x4<T, P> const& m, T s, T t)
{ {
tmat4x4<T, P> r(1); tmat4x4<T, P> r(1);
r[0][1] = s; r[1][0] = s;
r[2][1] = t; r[1][2] = t;
return m * r; return m * r;
} }
@ -41,8 +41,8 @@ namespace glm
GLM_FUNC_QUALIFIER tmat4x4<T, P> shearZ3D(tmat4x4<T, P> const& m, T s, T t) GLM_FUNC_QUALIFIER tmat4x4<T, P> shearZ3D(tmat4x4<T, P> const& m, T s, T t)
{ {
tmat4x4<T, P> r(1); tmat4x4<T, P> r(1);
r[0][2] = s; r[2][0] = s;
r[1][2] = t; r[2][1] = t;
return m * r; return m * r;
} }

View File

@ -57,6 +57,7 @@ glm::mat4 camera(float Translate, glm::vec2 const & Rotate)
##### Fixes: ##### Fixes:
- Fixed Android build error with C++11 compiler but C++98 STL #284 #564 - Fixed Android build error with C++11 compiler but C++98 STL #284 #564
- Fixed GTX_transform2 shear* functions #403
#### [GLM 0.9.8.2](https://github.com/g-truc/glm/releases/tag/0.9.8.2) - 2016-11-01 #### [GLM 0.9.8.2](https://github.com/g-truc/glm/releases/tag/0.9.8.2) - 2016-11-01
##### Improvements: ##### Improvements: