5 #if !defined(LST_MATRIX_H__INCLUDED_)
6 #define LST_MATRIX_H__INCLUDED_
10 #include "Utility/DPoint.h"
24 CMatrix(
double r0c0,
double r0c1,
double r1c0,
double r1c1,
double r2c0,
double r2c1)
39 void setTransform(
double r0c0,
double r0c1,
double r1c0,
double r1c1,
double r2c0,
double r2c1)
70 matrix[5] = mat.
matrix[4] * b1 + mat.
matrix[5] * d1 + matrix[5];
75 void scale(
double x,
double y)
77 CMatrix scaleMatrix( x, 0.0, 0.0, y, 0.0, 0.0);
85 CMatrix rotateMatrix(cos(radians), sin(radians), -sin(radians), cos(radians), 0.0, 0.0);
94 CMatrix transMatrix(1.0, 0.0, 0.0, 1.0, x, y);
104 for (i = 0; i < 6; i++)
117 for (i = 0; i < 6; i++)
154 #endif // LST_MATRIX_H__INCLUDED_
void setTransform(double *mat)
set matrix to specified matrix
Definition: Matrix.h:47
void rotate(double radians)
rotate matrix
Definition: Matrix.h:83
void setTransform(double r0c0, double r0c1, double r1c0, double r1c1, double r2c0, double r2c1)
set matrix to specified values
Definition: Matrix.h:39
CMatrix(double *mat)
constructor - intialize to specified matrix
Definition: Matrix.h:22
DPoint transformPt(DPoint point)
translate a point
Definition: Matrix.h:128
double matrix[6]
matrix values
Definition: Matrix.h:150
void multiply(CMatrix &mat)
multiply matrix
Definition: Matrix.h:58
void scale(DPoint scl)
scale matrix
Definition: Matrix.h:74
bool operator==(CMatrix &mat)
matrix equals operator
Definition: Matrix.h:100
void translate(DPoint trans)
translate matrix
Definition: Matrix.h:91
void setToIdentity()
set indentity matrix
Definition: Matrix.h:32
CMatrix(double r0c0, double r0c1, double r1c0, double r1c1, double r2c0, double r2c1)
constructor - intialize to specified values
Definition: Matrix.h:24
CMatrix – transform matrix class.
Definition: Matrix.h:16
DPoint transformVec(DPoint vec)
translate a vector
Definition: Matrix.h:139
bool operator!=(CMatrix &mat)
matrix not-equals operator
Definition: Matrix.h:113
CMatrix()
Default constructor - intialize to indentity matrix.
Definition: Matrix.h:20