TexGen
|
Represents a linear transformation as a 3x3 matrix. More...
#include <LinearTransformation.h>
Public Member Functions | |
CLinearTransformation (void) | |
CLinearTransformation (const CMatrix &Matrix) | |
~CLinearTransformation (void) | |
void | ResetTransformation () |
void | MultiplyTransformation (const CMatrix &Deformation) |
void | AddScale (double dXScale=1, double dYScale=1, double dZScale=1) |
void | AddSheardYbydX (double dValue) |
void | AddSheardZbydX (double dValue) |
void | AddSheardXbydY (double dValue) |
void | AddSheardZbydY (double dValue) |
void | AddSheardXbydZ (double dValue) |
void | AddSheardYbydZ (double dValue) |
void | Rotate (WXYZ Rotation) |
void | Initialise (int iHeight, int iWidth) |
void | InitialiseIdentity (int iSize) |
CMatrix | GetTranspose () |
CMatrix & | GetSubMatrix (CMatrix &SubMatrix, int iRow, int iColumn) const |
void | SetSubMatrix (CMatrix &SubMatrix, int iRow, int iColumn) |
void | ZeroMatrix () |
double & | operator() (int i, int j) |
const double & | operator() (int i, int j) const |
const double | GetValue (int i, int j) const |
void | SetValue (int i, int j, double dVal) |
CMatrix | operator* (const CMatrix &RightMatrix) const |
CMatrix | operator* (double dRight) const |
CMatrix | operator+ (const CMatrix &RightMatrix) const |
CMatrix | operator- (const CMatrix &RightMatrix) const |
CMatrix & | operator*= (double dRight) |
CMatrix & | operator/= (double dRight) |
CMatrix & | operator+= (const CMatrix &RightMatrix) |
CMatrix & | operator-= (const CMatrix &RightMatrix) |
double | GetDeterminant () const |
double | GetInverse (CMatrix &Inverse) const |
void | GetSquareRoot (CMatrix &Root) const |
void | GetEigen (CMatrix &EigenVectors, CMatrix &EigenValues) const |
void | GetPolarDecomposition (CMatrix &U, CMatrix &P) const |
bool | Empty () const |
int | GetHeight () const |
int | GetWidth () const |
void | SwapRows (int iRow1, int iRow2) |
void | SwapColumns (int iColumn1, int iColumn2) |
void | DivideRow (int iRow, double dDivisor) |
void | DivideColumn (int iColumn, double dDivisor) |
void | SubtractRow (int iRow1, int iRow2, double dScale) |
void | SubtractColumn (int iColumn1, int iColumn2, double dScale) |
void | Identity () |
CMatrix & | EqualsMultiple (const CMatrix &LeftMatrix, const CMatrix &RightMatrix) |
This function multiplies the left matrix with the right matrix. More... | |
CMatrix & | EqualsTransposeMultiple (const CMatrix &LeftMatrix, const CMatrix &RightMatrix) |
This function multiplies the transpose of the left matrix with the right matrix. More... | |
CMatrix & | EqualsMultipleTranspose (const CMatrix &LeftMatrix, const CMatrix &RightMatrix) |
This function multiplies the transpose of the left matrix with the right matrix. More... | |
void | PrintMatrix (char szMatrixName[], ostream &Output=cout, int iWidth=16, bool bScientific=true) |
Protected Member Functions | |
double | GetInverseSlow (CMatrix &Inverse) const |
Protected Attributes | |
int | m_iWidth |
int | m_iHeight |
double * | m_dMatrix |
Represents a linear transformation as a 3x3 matrix.
This class is derived from the CMatrix class, and adds a few additional functions specific to 3x3 linear transformation matrices.
Definition at line 38 of file LinearTransformation.h.
CLinearTransformation::CLinearTransformation | ( | void | ) |
Definition at line 25 of file LinearTransformation.cpp.
References TexGen::CMatrix::InitialiseIdentity().
CLinearTransformation::CLinearTransformation | ( | const CMatrix & | Matrix | ) |
Definition at line 30 of file LinearTransformation.cpp.
References TexGen::CMatrix::GetHeight(), TexGen::CMatrix::GetWidth(), TexGen::CMatrix::InitialiseIdentity(), and TGERROR.
CLinearTransformation::~CLinearTransformation | ( | void | ) |
Definition at line 43 of file LinearTransformation.cpp.
void CLinearTransformation::AddScale | ( | double | dXScale = 1 , |
double | dYScale = 1 , |
||
double | dZScale = 1 |
||
) |
Definition at line 57 of file LinearTransformation.cpp.
References TexGen::CMatrix::InitialiseIdentity(), and MultiplyTransformation().
|
inline |
Definition at line 50 of file LinearTransformation.h.
|
inline |
Definition at line 52 of file LinearTransformation.h.
|
inline |
Definition at line 48 of file LinearTransformation.h.
|
inline |
Definition at line 53 of file LinearTransformation.h.
|
inline |
Definition at line 49 of file LinearTransformation.h.
|
inline |
Definition at line 51 of file LinearTransformation.h.
|
inlineinherited |
Definition at line 755 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 743 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 171 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Referenced by TexGen::CMatrix::operator+=(), and TexGen::CMatrix::operator-=().
|
inlineinherited |
This function multiplies the left matrix with the right matrix.
Warning, LeftMatrix and RightMatrix parameters should not be equal to this
Definition at line 293 of file Matrix.h.
References TexGen::CMatrix::Initialise(), TexGen::CMatrix::m_iHeight, TexGen::CMatrix::m_iWidth, and TexGen::CMatrix::ZeroMatrix().
Referenced by TexGen::CElement::GetBMatrix(), TexGen::CElementTriTension::GetDMatrix(), TexGen::CInterpolationCubic::GetNaturalCubicSplines(), TexGen::CInterpolationCubic::GetPeriodicCubicSplines(), TexGen::CMatrix::GetPolarDecomposition(), and TexGen::CMatrix::GetSquareRoot().
|
inlineinherited |
This function multiplies the transpose of the left matrix with the right matrix.
Warning, LeftMatrix and RightMatrix parameters should not be equal to this
Definition at line 347 of file Matrix.h.
References TexGen::CMatrix::Initialise(), TexGen::CMatrix::m_iHeight, TexGen::CMatrix::m_iWidth, and TexGen::CMatrix::ZeroMatrix().
Referenced by TexGen::CElementTriBending::GetDMatrix().
|
inlineinherited |
This function multiplies the transpose of the left matrix with the right matrix.
Warning, LeftMatrix and RightMatrix parameters should not be equal to this
Definition at line 320 of file Matrix.h.
References TexGen::CMatrix::Initialise(), TexGen::CMatrix::m_iHeight, TexGen::CMatrix::m_iWidth, and TexGen::CMatrix::ZeroMatrix().
Referenced by TexGen::CElement::GetKeMatrix(), and TexGen::CMatrix::GetPolarDecomposition().
|
inlineinherited |
Definition at line 489 of file Matrix.h.
References TexGen::CMatrix::GetInverse(), TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Referenced by TexGen::CElementTri::GetArea(), TexGen::CMatrix::GetInverse(), and TexGen::CMatrix::GetInverseSlow().
|
inlineinherited |
Definition at line 827 of file Matrix.h.
References TexGen::CMatrix::Initialise(), TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Referenced by TexGen::CMatrix::GetSquareRoot().
|
inlineinherited |
Definition at line 176 of file Matrix.h.
References TexGen::CMatrix::m_iHeight.
Referenced by CLinearTransformation().
|
inlineinherited |
Definition at line 544 of file Matrix.h.
References TexGen::CMatrix::GetDeterminant(), TexGen::CMatrix::Identity(), TexGen::CMatrix::Initialise(), TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Referenced by TexGen::CDomainPlanes::Deform(), TexGen::CElement::GetBMatrix(), TexGen::CMatrix::GetDeterminant(), TexGen::CElementTriBending::GetDMatrix(), TexGen::CElementTriTension::GetDMatrix(), TexGen::CInterpolationCubic::GetNaturalCubicSplines(), TexGen::CInterpolationCubic::GetPeriodicCubicSplines(), TexGen::CMatrix::GetPolarDecomposition(), and TexGen::CMatrix::GetSquareRoot().
|
inlineprotectedinherited |
Definition at line 677 of file Matrix.h.
References TexGen::CMatrix::GetDeterminant(), TexGen::CMatrix::GetSubMatrix(), TexGen::CMatrix::Initialise(), TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Definition at line 817 of file Matrix.h.
References TexGen::CMatrix::EqualsMultiple(), TexGen::CMatrix::EqualsTransposeMultiple(), TexGen::CMatrix::GetInverse(), TexGen::CMatrix::GetSquareRoot(), TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 461 of file Matrix.h.
References TexGen::CMatrix::EqualsMultiple(), TexGen::CMatrix::GetEigen(), TexGen::CMatrix::GetInverse(), TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Referenced by TexGen::CMatrix::GetPolarDecomposition().
|
inlineinherited |
Definition at line 793 of file Matrix.h.
References TexGen::CMatrix::Initialise(), TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Referenced by TexGen::CMatrix::GetInverseSlow().
|
inlineinherited |
Definition at line 220 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Referenced by TexGen::CDomainPlanes::Deform().
|
inlineinherited |
Definition at line 200 of file Matrix.h.
References TexGen::CMatrix::m_dMatrix, and TexGen::CMatrix::m_iWidth.
Referenced by TexGen::CMatrix::SetSubMatrix().
|
inlineinherited |
Definition at line 181 of file Matrix.h.
References TexGen::CMatrix::m_iWidth.
Referenced by CLinearTransformation().
|
inlineinherited |
Definition at line 527 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Referenced by TexGen::CMatrix::GetInverse(), TexGen::CMatrix::InitialiseIdentity(), and ResetTransformation().
|
inlineinherited |
Definition at line 144 of file Matrix.h.
References TexGen::CMatrix::m_dMatrix, TexGen::CMatrix::m_iHeight, TexGen::CMatrix::m_iWidth, and TexGen::CMatrix::ZeroMatrix().
Referenced by TexGen::CMatrix::EqualsMultiple(), TexGen::CMatrix::EqualsMultipleTranspose(), TexGen::CMatrix::EqualsTransposeMultiple(), TexGen::CElementTriBending::GetAMatrix(), TexGen::CElementTriTension::GetAMatrix(), TexGen::CElementTriBending::GetDMatrix(), TexGen::CElementTriTension::GetDMatrix(), TexGen::CMatrix::GetEigen(), TexGen::CElementTri::GetIntegrationPoints(), TexGen::CMatrix::GetInverse(), TexGen::CMatrix::GetInverseSlow(), TexGen::CMatrix::GetSubMatrix(), TexGen::CElementTriBending::GetXMatrix(), TexGen::CElementTriTension::GetXMatrix(), TexGen::operator*(), TexGen::CMatrix::operator+=(), TexGen::CMatrix::operator-=(), and TexGen::CMatrix::operator=().
|
inlineinherited |
Definition at line 155 of file Matrix.h.
References TexGen::CMatrix::Identity(), TexGen::CMatrix::m_dMatrix, TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Referenced by AddScale(), CLinearTransformation(), TexGen::ConvertRotation(), and TexGen::CTextileDeformer::CTextileDeformer().
void CLinearTransformation::MultiplyTransformation | ( | const CMatrix & | Deformation | ) |
Definition at line 52 of file LinearTransformation.cpp.
Referenced by AddScale(), and Rotate().
|
inlineinherited |
Definition at line 186 of file Matrix.h.
References TexGen::CMatrix::m_dMatrix, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 193 of file Matrix.h.
References TexGen::CMatrix::m_dMatrix, and TexGen::CMatrix::m_iWidth.
Definition at line 234 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 252 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 374 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Definition at line 266 of file Matrix.h.
References TexGen::CMatrix::m_dMatrix, TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Definition at line 401 of file Matrix.h.
References TexGen::CMatrix::Empty(), TexGen::CMatrix::Initialise(), TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Definition at line 279 of file Matrix.h.
References TexGen::CMatrix::m_dMatrix, TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Definition at line 419 of file Matrix.h.
References TexGen::CMatrix::Empty(), TexGen::CMatrix::Initialise(), TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 387 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 437 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Referenced by TexGen::operator<<().
void CLinearTransformation::ResetTransformation | ( | ) |
Definition at line 47 of file LinearTransformation.cpp.
References TexGen::CMatrix::Identity().
void CLinearTransformation::Rotate | ( | WXYZ | Rotation | ) |
Definition at line 95 of file LinearTransformation.cpp.
References TexGen::ConvertRotation(), and MultiplyTransformation().
|
inlineinherited |
Definition at line 1119 of file Matrix.h.
References TexGen::CMatrix::GetValue(), TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 207 of file Matrix.h.
References TexGen::CMatrix::m_dMatrix, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 780 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 767 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 727 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 711 of file Matrix.h.
References TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
|
inlineinherited |
Definition at line 215 of file Matrix.h.
References TexGen::CMatrix::m_dMatrix, TexGen::CMatrix::m_iHeight, and TexGen::CMatrix::m_iWidth.
Referenced by TexGen::CMatrix::CMatrix(), TexGen::CMatrix::EqualsMultiple(), TexGen::CMatrix::EqualsMultipleTranspose(), TexGen::CMatrix::EqualsTransposeMultiple(), TexGen::CElement::GetKeMatrix(), and TexGen::CMatrix::Initialise().
|
protectedinherited |
Definition at line 101 of file Matrix.h.
Referenced by TexGen::CMatrix::CMatrix(), TexGen::CMatrix::GetValue(), TexGen::CMatrix::Initialise(), TexGen::CMatrix::InitialiseIdentity(), TexGen::CMatrix::operator()(), TexGen::CMatrix::operator+(), TexGen::CMatrix::operator-(), TexGen::CMatrix::operator=(), TexGen::CMatrix::SetValue(), TexGen::CMatrix::ZeroMatrix(), and TexGen::CMatrix::~CMatrix().
|
protectedinherited |
Definition at line 100 of file Matrix.h.
Referenced by TexGen::CMatrix::CMatrix(), TexGen::CMatrix::DivideColumn(), TexGen::CMatrix::DivideRow(), TexGen::CMatrix::Empty(), TexGen::CMatrix::EqualsMultiple(), TexGen::CMatrix::EqualsMultipleTranspose(), TexGen::CMatrix::EqualsTransposeMultiple(), TexGen::CMatrix::GetDeterminant(), TexGen::CMatrix::GetEigen(), TexGen::CMatrix::GetHeight(), TexGen::CMatrix::GetInverse(), TexGen::CMatrix::GetInverseSlow(), TexGen::CMatrix::GetPolarDecomposition(), TexGen::CMatrix::GetSquareRoot(), TexGen::CMatrix::GetSubMatrix(), TexGen::CMatrix::GetTranspose(), TexGen::CMatrix::Identity(), TexGen::CMatrix::Initialise(), TexGen::CMatrix::InitialiseIdentity(), TexGen::CMatrix::operator*(), TexGen::CMatrix::operator*=(), TexGen::CMatrix::operator+(), TexGen::CMatrix::operator+=(), TexGen::CMatrix::operator-(), TexGen::CMatrix::operator-=(), TexGen::CMatrix::operator/=(), TexGen::CMatrix::operator=(), TexGen::CMatrix::PrintMatrix(), TexGen::CMatrix::SetSubMatrix(), TexGen::CMatrix::SubtractColumn(), TexGen::CMatrix::SubtractRow(), TexGen::CMatrix::SwapColumns(), TexGen::CMatrix::SwapRows(), and TexGen::CMatrix::ZeroMatrix().
|
protectedinherited |
Definition at line 99 of file Matrix.h.
Referenced by TexGen::CMatrix::CMatrix(), TexGen::CMatrix::DivideColumn(), TexGen::CMatrix::DivideRow(), TexGen::CMatrix::Empty(), TexGen::CMatrix::EqualsMultiple(), TexGen::CMatrix::EqualsMultipleTranspose(), TexGen::CMatrix::EqualsTransposeMultiple(), TexGen::CMatrix::GetDeterminant(), TexGen::CMatrix::GetEigen(), TexGen::CMatrix::GetInverse(), TexGen::CMatrix::GetInverseSlow(), TexGen::CMatrix::GetPolarDecomposition(), TexGen::CMatrix::GetSquareRoot(), TexGen::CMatrix::GetSubMatrix(), TexGen::CMatrix::GetTranspose(), TexGen::CMatrix::GetValue(), TexGen::CMatrix::GetWidth(), TexGen::CMatrix::Identity(), TexGen::CMatrix::Initialise(), TexGen::CMatrix::InitialiseIdentity(), TexGen::CMatrix::operator()(), TexGen::CMatrix::operator*(), TexGen::CMatrix::operator*=(), TexGen::CMatrix::operator+(), TexGen::CMatrix::operator+=(), TexGen::CMatrix::operator-(), TexGen::CMatrix::operator-=(), TexGen::CMatrix::operator/=(), TexGen::CMatrix::operator=(), TexGen::CMatrix::PrintMatrix(), TexGen::CMatrix::SetSubMatrix(), TexGen::CMatrix::SetValue(), TexGen::CMatrix::SubtractColumn(), TexGen::CMatrix::SubtractRow(), TexGen::CMatrix::SwapColumns(), TexGen::CMatrix::SwapRows(), and TexGen::CMatrix::ZeroMatrix().