Nori
|
Homogeneous coordinate transformation. More...
#include <transform.h>
Public Member Functions | |
Transform () | |
Create the identity transform. | |
Transform (const Eigen::Matrix4f &trafo) | |
Create a new transform instance for the given matrix. | |
Transform (const Eigen::Matrix4f &trafo, const Eigen::Matrix4f &inv) | |
Create a new transform instance for the given matrix and its inverse. | |
const Eigen::Matrix4f & | getMatrix () const |
Return the underlying matrix. | |
const Eigen::Matrix4f & | getInverseMatrix () const |
Return the inverse of the underlying matrix. | |
Transform | inverse () const |
Return the inverse transformation. | |
Transform | operator* (const Transform &t) const |
Concatenate with another transform. | |
Vector3f | operator* (const Vector3f &v) const |
Apply the homogeneous transformation to a 3D vector. | |
Normal3f | operator* (const Normal3f &n) const |
Apply the homogeneous transformation to a 3D normal. | |
Point3f | operator* (const Point3f &p) const |
Transform a point by an arbitrary matrix in homogeneous coordinates. | |
Ray3f | operator& (const Ray3f &r) const |
Apply the homogeneous transformation to a ray. | |
QString | toString () const |
Return a string representation. |
Homogeneous coordinate transformation.
This class stores a general homogeneous coordinate tranformation, such as rotation, translation, uniform or non-uniform scaling, and perspective transformations. The inverse of this transformation is also recorded here, since it is required when transforming normal vectors.
Definition at line 35 of file transform.h.
Transform::Transform | ( | ) | [inline] |
Create the identity transform.
Definition at line 38 of file transform.h.
Transform::Transform | ( | const Eigen::Matrix4f & | trafo | ) |
Create a new transform instance for the given matrix.
Transform::Transform | ( | const Eigen::Matrix4f & | trafo, |
const Eigen::Matrix4f & | inv | ||
) | [inline] |
Create a new transform instance for the given matrix and its inverse.
Definition at line 46 of file transform.h.
const Eigen::Matrix4f& Transform::getInverseMatrix | ( | ) | const [inline] |
Return the inverse of the underlying matrix.
Definition at line 55 of file transform.h.
const Eigen::Matrix4f& Transform::getMatrix | ( | ) | const [inline] |
Return the underlying matrix.
Definition at line 50 of file transform.h.
Transform Transform::inverse | ( | ) | const [inline] |
Return the inverse transformation.
Definition at line 60 of file transform.h.
Apply the homogeneous transformation to a ray.
Definition at line 84 of file transform.h.
Transform a point by an arbitrary matrix in homogeneous coordinates.
Definition at line 78 of file transform.h.
Apply the homogeneous transformation to a 3D vector.
Definition at line 68 of file transform.h.
Apply the homogeneous transformation to a 3D normal.
Definition at line 73 of file transform.h.
QString Transform::toString | ( | ) | const |
Return a string representation.