| OGRE 1.11.1 Object-Oriented Graphics Rendering Engine

Public Member Functions | Static Public Member Functions | Static Public Attributes | List of all members
Ogre::Affine3 Class Reference
Core » Math

Transform specialization for 3D Affine - encapsulating a 3x4 Matrix. More...

`#include <OgreMatrix4.h>`

Inheritance diagram for Ogre::Affine3:
[legend]

## Public Member Functions
| Affine3 ()
| Do NOT initialize the matrix for efficiency. More...
| Affine3 (const Vector3 &position, const Quaternion &orientation, const Vector3 &scale=Vector3::UNIT_SCALE)
| Building a Affine3 from orientation / scale / position. More...
| Affine3 (Real m00, Real m01, Real m02, Real m03, Real m10, Real m11, Real m12, Real m13, Real m20, Real m21, Real m22, Real m23)
| Affine3 (const Matrix4 &mat)
| extract the Affine part of a Matrix4 More...
void | decomposition (Vector3 &position, Vector3 &scale, Quaternion &orientation) const
| Decompose to orientation / scale / position. More...
Real | determinant () const
void | extract3x3Matrix (Matrix3 &m3x3) const
Quaternion | extractQuaternion () const
Vector3 | getTrans () const
| Extracts the translation transformation part of the matrix. More...
Vector3 | getTrans () const
| Extracts the translation transformation part of the matrix. More...
Affine3 | inverse () const
Matrix3 | linear () const
| Extracts the rotation / scaling part of the Matrix as a 3x3 matrix. More...
void | makeInverseTransform (const Vector3 &position, const Vector3 &scale, const Quaternion &orientation)
| Building an inverse Affine3 from orientation / scale / position. More...
void | makeTrans (const Vector3 &v)
| Builds a translation matrix. More...
void | makeTrans (Real tx, Real ty, Real tz)
void | makeTransform (const Vector3 &position, const Vector3 &scale, const Quaternion &orientation)
| Building a Affine3 from orientation / scale / position. More...
| operator const Matrix4 & () const
| every Affine3 transform is also a const Matrix4 More...
bool | operator!= (const Affine3 &m2) const
Affine3 & | operator= (const Matrix3 &mat3)
bool | operator== (const Affine3 &m2) const
| Tests 2 matrices for equality. More...
Real * | operator[] (size_t iRow)
const Real * | operator[] (size_t iRow) const
void | set3x3Matrix (const Matrix3 &mat3)
| Assignment from 3x3 matrix. More...
void | setScale (const Vector3 &v)
| Sets the scale part of the matrix. More...
void | setTrans (const Vector3 &v)
| Sets the translation transformation part of the matrix. More...
Matrix4 | transpose () const

## Static Public Member Functions
static Affine3 | getScale (const Vector3 &v)
| Gets a scale matrix. More...
static Affine3 | getScale (Real s_x, Real s_y, Real s_z)
| Gets a scale matrix - variation for not using a vector. More...
static Affine3 | getTrans (const Vector3 &v)
| Gets a translation matrix. More...
static Affine3 | getTrans (Real t_x, Real t_y, Real t_z)
| Gets a translation matrix - variation for not using a vector. More...

## Static Public Attributes
static const Affine3 | IDENTITY
static const Affine3 | ZERO

## Detailed Description

Transform specialization for 3D Affine - encapsulating a 3x4 Matrix.

## Constructor & Destructor Documentation

## ◆ Affine3() [1/4]

Ogre::Affine3::Affine3 | ( |  | ) |
| inline

Do NOT initialize the matrix for efficiency.

## ◆ Affine3() [2/4]

Ogre::Affine3::Affine3 | ( | const Vector3 & | position,
|  | const Quaternion & | orientation,
|  | const Vector3 & | scale = `Vector3::UNIT_SCALE`
| ) |  |
| inline

Building a Affine3 from orientation / scale / position.

Remarks
  Transform is performed in the order scale, rotate, translation, i.e. translation is independent of orientation axes, scale does not affect size of translation, rotation and scaling are always centered on the origin.

## ◆ Affine3() [3/4]

Ogre::Affine3::Affine3 | ( | Real | m00,
|  | Real | m01,
|  | Real | m02,
|  | Real | m03,
|  | Real | m10,
|  | Real | m11,
|  | Real | m12,
|  | Real | m13,
|  | Real | m20,
|  | Real | m21,
|  | Real | m22,
|  | Real | m23
| ) |  |
| inline

## ◆ Affine3() [4/4]

Ogre::Affine3::Affine3 | ( | const Matrix4 & | mat | ) |
| inline explicit

extract the Affine part of a Matrix4

## Member Function Documentation

## ◆ operator=()

Affine3& Ogre::Affine3::operator= | ( | const Matrix3 & | mat3 | ) |
| inline

## ◆ operator==()

bool Ogre::Affine3::operator== | ( | const Affine3 & | m2 | ) | const
| inline

Tests 2 matrices for equality.

## ◆ operator!=()

bool Ogre::Affine3::operator!= | ( | const Affine3 & | m2 | ) | const
| inline

## ◆ inverse()

Affine3 Ogre::Affine3::inverse | ( |  | ) | const

## ◆ decomposition()

void Ogre::Affine3::decomposition | ( | Vector3 & | position,
|  | Vector3 & | scale,
|  | Quaternion & | orientation
| ) |  | const

Decompose to orientation / scale / position.

## ◆ operator const Matrix4 &()

Ogre::Affine3::operator const Matrix4 & | ( |  | ) | const
| inline

every Affine3 transform is also a const Matrix4

## ◆ getTrans() [1/4]

static Affine3 Ogre::Affine3::getTrans | ( | const Vector3 & | v | ) |
| inline static

Gets a translation matrix.

References Ogre::Vector3::x, Ogre::Vector3::y, and Ogre::Vector3::z.

## ◆ getTrans() [2/4]

static Affine3 Ogre::Affine3::getTrans | ( | Real | t_x,
|  | Real | t_y,
|  | Real | t_z
| ) |  |
| inline static

Gets a translation matrix - variation for not using a vector.

## ◆ getScale() [1/2]

static Affine3 Ogre::Affine3::getScale | ( | const Vector3 & | v | ) |
| inline static

Gets a scale matrix.

References Ogre::Vector3::x, Ogre::Vector3::y, and Ogre::Vector3::z.

## ◆ getScale() [2/2]

static Affine3 Ogre::Affine3::getScale | ( | Real | s_x,
|  | Real | s_y,
|  | Real | s_z
| ) |  |
| inline static

Gets a scale matrix - variation for not using a vector.

## ◆ getTrans() [3/4]

Vector3 Ogre::TransformBase::getTrans
| inline

Extracts the translation transformation part of the matrix.

## ◆ operator[]() [1/2]

Real* Ogre::TransformBase::operator[] | ( | size_t | iRow | ) |
| inline inherited

## ◆ operator[]() [2/2]

const Real* Ogre::TransformBase::operator[] | ( | size_t | iRow | ) | const
| inline inherited

## ◆ set3x3Matrix()

void Ogre::TransformBase::set3x3Matrix | ( | const Matrix3 & | mat3 | ) |
| inline inherited

Assignment from 3x3 matrix.

## ◆ linear()

Matrix3 Ogre::TransformBase::linear | ( |  | ) | const
| inline inherited

Extracts the rotation / scaling part of the Matrix as a 3x3 matrix.

## ◆ extract3x3Matrix()

void Ogre::TransformBase::extract3x3Matrix | ( | Matrix3 & | m3x3 | ) | const
| inline inherited

## ◆ extractQuaternion()

Quaternion Ogre::TransformBase::extractQuaternion | ( |  | ) | const
| inline inherited

## ◆ setTrans()

void Ogre::TransformBase::setTrans | ( | const Vector3 & | v | ) |
| inline inherited

Sets the translation transformation part of the matrix.

References Ogre::Vector3::x, Ogre::Vector3::y, and Ogre::Vector3::z.

## ◆ getTrans() [4/4]

Vector3 Ogre::TransformBase::getTrans | ( |  | ) | const
| inline inherited

Extracts the translation transformation part of the matrix.

## ◆ setScale()

void Ogre::TransformBase::setScale | ( | const Vector3 & | v | ) |
| inline inherited

Sets the scale part of the matrix.

References Ogre::Vector3::x, Ogre::Vector3::y, and Ogre::Vector3::z.

## ◆ makeTrans() [1/2]

void Ogre::TransformBase::makeTrans | ( | const Vector3 & | v | ) |
| inline inherited

Builds a translation matrix.

References Ogre::Vector3::x, Ogre::Vector3::y, and Ogre::Vector3::z.

## ◆ makeTrans() [2/2]

void Ogre::TransformBase::makeTrans | ( | Real | tx,
|  | Real | ty,
|  | Real | tz
| ) |  |
| inline inherited

## ◆ determinant()

Real Ogre::TransformBase::determinant | ( |  | ) | const
| inherited

## ◆ makeTransform()

void Ogre::TransformBase::makeTransform | ( | const Vector3 & | position,
|  | const Vector3 & | scale,
|  | const Quaternion & | orientation
| ) |  |
| inherited

Building a Affine3 from orientation / scale / position.

Remarks
  Transform is performed in the order scale, rotate, translation, i.e. translation is independent of orientation axes, scale does not affect size of translation, rotation and scaling are always centered on the origin.

## ◆ makeInverseTransform()

void Ogre::TransformBase::makeInverseTransform | ( | const Vector3 & | position,
|  | const Vector3 & | scale,
|  | const Quaternion & | orientation
| ) |  |
| inherited

Building an inverse Affine3 from orientation / scale / position.

Remarks
  As makeTransform except it build the inverse given the same data as makeTransform, so performing -translation, -rotate, 1/scale in that order.

## Member Data Documentation

## ◆ ZERO

const Affine3 Ogre::Affine3::ZERO
| static

## ◆ IDENTITY

const Affine3 Ogre::Affine3::IDENTITY
| static

Referenced by Ogre::InstancedEntity::_getParentNodeFullTransform().

The documentation for this class was generated from the following file:

- OgreMatrix4.h