TransformationData Struct Reference

#include <DataTypes.h>

List of all members.


Public Attributes

gmtl::Vec3f position
gmtl::Vec3f scale
gmtl::Quatf orientation
gmtl::Quatf scaleOrientation

Detailed Description

Struct for storing general geometrical transformations. It has been introduced because it can be used more intuitively than matrices. An invertible transformation matrix (that is an invertible 4x4 matrix which has (0, 0, 0, 1) in the last row) can be converted into a TransformationData and vice versa (though this conversion is not unique). The matrix which corresponds to a TransformationData is obtained by applying ('*') the components in the following order: (position * orientation * inverse(scaleOrientation) * scale * scaleOrientation).

A vector v transformed by a TransformationData is defined by multiplying the equivalent matrix M with the vector v' = Mv (so first the vector is rotated by the quaternion scaleOrientation, then it is scaled in the (x,y,z) direction by the scale vector, afterwards its rotated by the inverse of the scaleOrientation and so on).

When two TransformationData are multiplied the resulting TransformationData is the same as multiplying the both equivalent matrices.


Member Data Documentation


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

Generated on Wed Oct 20 16:12:01 2010 for inVRs by doxygen 1.5.8