Classes | |
class | Matrix44 |
Class to handle square 4x4 matrix This class is build not to handle a general 4x4 matrix but to work with linear function in omogeneous space. More... | |
class | Vector4 |
Class representing an omogeneous vector. More... | |
Enumerations | |
enum | MainAxis { X_AXIS, Y_AXIS, Z_AXIS } |
This enum is used to specify rotation axis for various functions of Matrix44. | |
Functions | |
Matrix44 & | Matrix44Multiply (const Matrix44 &M1, const Matrix44 &M2, Matrix44 &Result) |
Matrix Multiplication, result is stored in new matrix. | |
Matrix44 & | Matrix44MultiplyL (Matrix44 &M1_result, const Matrix44 &M2) |
Matrix Multiplication, result is stored in first matrix. | |
Matrix44 & | Matrix44MultiplyR (const Matrix44 &M1, Matrix44 &M2_result) |
Matrix Multiplication, result is stored in first matrix. | |
const Matrix44 | operator * (const Matrix44 &M1, const Matrix44 &M2) |
Operators * for class Matrix44. | |
Matrix44 & | operator *= (Matrix44 &M1, const Matrix44 &M2) |
Operators *= for class Matrix44. | |
std::ostream & | operator<< (std::ostream &outStream, const Matrix44 &Mat) |
To print Matrix44 Element with standard stream, useful for debugging. | |
const Vector4 | operator * (const Matrix44 &M, const Vector4 &V) |
Multiply a Matrix44 for a vector, remember that I use column vectors. | |
const Vector4 | operator- (const Vector4 &V) |
Negate a vector, same module, same direction opposite verse. | |
const Vector4 | operator * (const Vector4 &V1, const Vector4 &V2) |
Cross product between two vectors in a Rigth handed coordinate system. | |
const Vector4 | operator- (const Vector4 &V1, const Vector4 &V2) |
Subtraction between two vertex. | |
const Vector4 | operator+ (const Vector4 &V1, const Vector4 &V2) |
Addiction between two vertex. | |
float | Dot (const Vector4 &V1, const Vector4 &V2) |
External function to do Dot operation, this because operator * is used for cross product. | |
std::ostream & | operator<< (std::ostream &outStream, const Vector4 &V) |
To print Vector4 Element with standard stream, useful for debugging. |
|
Definition at line 164 of file Vector4.cpp. |
|
This function is used to multiply two Matrix44 object, pay attenction that the destination matrix cannot be one of the two matrix used for the operation. A call of the type Matrix44Multiply(M1, M1, M2) is wrong, use Matrix44MultiplyL(Matrix44 &, const Matrix44 &) instead. This fact is due to the implementation of this function that calculate one element at a time and immediatly store them in result matrix. This function is not to be used directly: to multiply two Matrix44 object is preferible to use the * operator.
Definition at line 26 of file Matrix44Operation.cpp. |
|
This is used to Transform a Vector44 by a transformation function expressed by a Matrix44, result is transformed vector.
Definition at line 117 of file Matrix44Operation.cpp. |
|
This is the usual * operator for 4x4 Matrix, both matrix object are passed as const reference because they must not be modified.
Definition at line 342 of file Matrix44.cpp. |
|
Operator *= for class Matrix44, it internally use the Matrix44MultiplyL function that multiply two matrix storing result in the Matrix44 object passed as first(left) parameter. It perform the operation M1 *= M2, since M2 matrix is not modified it is passed as const reference.
Definition at line 360 of file Matrix44.cpp. |
|
Unary minus operator is useful to change sign of a vector Definition at line 130 of file Vector4.cpp. |
|
Debugging routine that permit to output in a stream the content of a Vector44 object. Definition at line 119 of file Vector4.cpp. |
|
This is a standard implementation of operator << to output the content of a Matrix44 object to a std::outStream, it can be very useful because it's very easy to output content of a matrix to a file for debug purpose. Definition at line 372 of file Matrix44.cpp. |