1
0
Fork 0

include/Spectre/Math/Matrix3.h: minor comment fix.

This commit is contained in:
Henrik Hautakoski 2019-04-29 08:54:40 +02:00
parent 84d773dc0d
commit 7bf8617267
No known key found for this signature in database
GPG key ID: 839F3A7EAFAEAFAA

View file

@ -10,7 +10,11 @@
template<typename T> template<typename T>
struct Matrix3 struct Matrix3
{ {
/* Column-major order are used for the matrices here to be compatible with OpenGL. // Column-major order are used for the matrices here to be compatible with OpenGL.
union {
T m[3][3]; // format: [col][row]
/* Indicies to use for accessing elements.
_ _ _ _
| | | |
| 0 3 6 | | 0 3 6 |
@ -18,8 +22,6 @@ struct Matrix3
| 2 5 8 | | 2 5 8 |
|_ _| |_ _|
*/ */
union {
T m[3][3]; // format: [col][row]
T v[9]; T v[9];
}; };
@ -27,6 +29,7 @@ struct Matrix3
inline Matrix3(); inline Matrix3();
inline Matrix3( T a, T b, T c, inline Matrix3( T a, T b, T c,
T d, T e, T f, T d, T e, T f,
T g, T h, T i); T g, T h, T i);