#include <OgreMatrix4.h>
Collaboration diagram for Ogre::Matrix4:
Public Methods | |
Matrix4 () | |
Default constructor. | |
Matrix4 (Real m00, Real m01, Real m02, Real m03, Real m10, Real m11, Real m12, Real m13, Real m20, Real m21, Real m22, Real m23, Real m30, Real m31, Real m32, Real m33) | |
Real * | operator[] (unsigned iRow) |
const Real *const | operator[] (unsigned iRow) const |
Matrix4 | concatenate (const Matrix4 &m2) const |
Matrix4 | operator * (const Matrix4 &m2) const |
Matrix concatenation using '*'. | |
Vector3 | operator * (const Vector3 &v) const |
Vector transformation using '*'. | |
Matrix4 | operator+ (const Matrix4 &m2) const |
Matrix addition. | |
Matrix4 | operator- (const Matrix4 &m2) const |
Matrix subtraction. | |
bool | operator== (const Matrix4 &m2) const |
Tests 2 matrices for equality. | |
bool | operator!= (Matrix4 &m2) const |
Tests 2 matrices for inequality. | |
void | operator= (const Matrix3 &mat3) |
Assignment from 3x3 matrix. | |
Matrix4 | transpose (void) const |
void | setTrans (const Vector3 &v) |
Sets the translation transformation part of the matrix. | |
void | makeTrans (const Vector3 &v) |
Builds a translation matrix. | |
void | makeTrans (Real tx, Real ty, Real tz) |
void | setScale (const Vector3 &v) |
Sets the scale part of the matrix. | |
void | extract3x3Matrix (Matrix3 &m3x3) const |
Extracts the rotation / scaling part of the Matrix as a 3x3 matrix. | |
Matrix4 | operator * (Real scalar) |
Matrix4 | adjoint () const |
Real | determinant () const |
Matrix4 | inverse () const |
Static Public Methods | |
Matrix4 | getTrans (const Vector3 &v) |
Gets a translation matrix. | |
Matrix4 | getTrans (Real t_x, Real t_y, Real t_z) |
Gets a translation matrix - variation for not using a vector. | |
Matrix4 | getScale (const Vector3 &v) |
Gets a scale matrix. | |
Matrix4 | getScale (Real s_x, Real s_y, Real s_z) |
Gets a scale matrix - variation for not using a vector. | |
Static Public Attributes | |
const Matrix4 | ZERO |
const Matrix4 | IDENTITY |
Friends | |
_OgreExport friend std::ostream & | operator<< (std::ostream &o, const Matrix4 &m) |
Function for writing to a stream. |
The use of column vectors and right-to-left ordering is the standard in most mathematical texts, and id the same as used in OpenGL. It is, however, the opposite of Direct3D, which has inexplicably chosen to differ from the accepted standard and uses row vectors and left-to-right matrix multiplication.
OGRE deals with the differences between D3D and OpenGL etc. internally when operating through different render systems. OGRE users only need to conform to standard maths conventions, i.e. right-to-left matrix multiplication, (OGRE transposes matrices it passes to D3D to compensate).
The generic form M * V which shows the layout of the matrix entries is shown below:
[ m[0][0] m[0][1] m[0][2] m[0][3] ] {x} | m[1][0] m[1][1] m[1][2] m[1][3] | * {y} | m[2][0] m[2][1] m[2][2] m[2][3] | {z} [ m[3][0] m[3][1] m[3][2] m[3][3] ] {1}
Definition at line 68 of file OgreMatrix4.h.
|
Default constructor.
Definition at line 81 of file OgreMatrix4.h. Referenced by adjoint(). |
|
Definition at line 85 of file OgreMatrix4.h. References Ogre::Real. |
|
Definition at line 56 of file OgreMatrix4.cpp. References Matrix4(), and Ogre::MINOR(). Referenced by inverse(). |
|
Definition at line 121 of file OgreMatrix4.h. References m. Referenced by Ogre::D3D9RenderSystem::_setTextureMatrix(), and Ogre::D3DRenderSystem::_setTextureMatrix(). |
|
Definition at line 80 of file OgreMatrix4.cpp. References m, Ogre::MINOR(), and Ogre::Real. Referenced by inverse(). |
|
Extracts the rotation / scaling part of the Matrix as a 3x3 matrix.
Definition at line 379 of file OgreMatrix4.h. References Ogre::Matrix3::m. Referenced by Ogre::RenderSystem::softwareVertexBlend(). |
|
Gets a scale matrix - variation for not using a vector.
Definition at line 365 of file OgreMatrix4.h. References m, and Ogre::Real. |
|
Gets a scale matrix.
Definition at line 352 of file OgreMatrix4.h. References m, Ogre::Vector3::x, Ogre::Vector3::y, and Ogre::Vector3::z. |
|
Gets a translation matrix - variation for not using a vector.
Definition at line 324 of file OgreMatrix4.h. References m, and Ogre::Real. |
|
Gets a translation matrix.
Definition at line 310 of file OgreMatrix4.h. References m, Ogre::Vector3::x, Ogre::Vector3::y, and Ogre::Vector3::z. |
|
Definition at line 88 of file OgreMatrix4.cpp. References adjoint(), and determinant(). Referenced by Ogre::AutoParamDataSource::getInverseViewMatrix(), Ogre::AutoParamDataSource::getInverseWorldMatrix(), and Ogre::AutoParamDataSource::getInverseWorldViewMatrix(). |
|
Definition at line 300 of file OgreMatrix4.h. References Ogre::Real. |
|
Builds a translation matrix.
Definition at line 292 of file OgreMatrix4.h. References Ogre::Vector3::x, Ogre::Vector3::y, and Ogre::Vector3::z. |
|
Definition at line 396 of file OgreMatrix4.h. References Ogre::Real. |
|
Vector transformation using '*'.
Definition at line 163 of file OgreMatrix4.h. References Ogre::Real, Ogre::Vector3::x, Ogre::Vector3::y, and Ogre::Vector3::z. |
|
Matrix concatenation using '*'.
Definition at line 149 of file OgreMatrix4.h. |
|
Tests 2 matrices for inequality.
Definition at line 248 of file OgreMatrix4.h. References m. |
|
Matrix addition.
Definition at line 178 of file OgreMatrix4.h. References m. |
|
Matrix subtraction.
Definition at line 207 of file OgreMatrix4.h. References m. |
|
Assignment from 3x3 matrix.
Definition at line 261 of file OgreMatrix4.h. References Ogre::Matrix3::m. |
|
Tests 2 matrices for equality.
Definition at line 235 of file OgreMatrix4.h. References m. |
|
Definition at line 115 of file OgreMatrix4.h. References Ogre::Real. |
|
Definition at line 109 of file OgreMatrix4.h. References Ogre::Real. |
|
Sets the scale part of the matrix.
Definition at line 343 of file OgreMatrix4.h. References Ogre::Vector3::x, Ogre::Vector3::y, and Ogre::Vector3::z. Referenced by Ogre::OctreeSceneManager::init(). |
|
Sets the translation transformation part of the matrix.
Definition at line 283 of file OgreMatrix4.h. References Ogre::Vector3::x, Ogre::Vector3::y, and Ogre::Vector3::z. Referenced by Ogre::MeshManager::createCurvedIllusionPlane(), Ogre::MeshManager::createCurvedPlane(), Ogre::MeshManager::createPlane(), Ogre::Node::makeInverseTransform(), Ogre::Node::makeTransform(), and Ogre::Overlay::updateTransform(). |
|
Definition at line 268 of file OgreMatrix4.h. Referenced by Ogre::GpuProgramParameters::setConstant(). |
|
Function for writing to a stream.
Definition at line 408 of file OgreMatrix4.h. |
|
Definition at line 74 of file OgreMatrix4.h. |
|
|
|
Definition at line 73 of file OgreMatrix4.h. Referenced by Ogre::D3D9RenderSystem::_setTextureMatrix(), Ogre::D3DRenderSystem::_setTextureMatrix(), concatenate(), Ogre::D3DRenderSystem::convertD3DMatrix(), determinant(), getScale(), getTrans(), Ogre::D3DRenderSystem::makeD3DMatrix(), Ogre::D3D9Mappings::makeD3DXMatrix(), operator!=(), operator+(), operator-(), and operator==(). |
|
|
Copyright © 2002-2003 by The OGRE Team
Last modified Wed Jan 21 00:18:07 2004