0
\$\begingroup\$

Some rendering engines like Ogre prefer to use a individual vector based notation for transformations like the following

Split vector notation: Net Transformation is represented by Scale vector = sx, sy, sz

Transformation vector = tx, ty, tz

Rotation Quaternion Vector = w,x,y,z

Matrix notation: There are other engines which simply use a net combined transformation matrix.

What are the advantages of the first notation over the second?

Also for animation interpolation does it work in the first notation that we interpolate across the individual components and use the interpolated parts to get the net transformation? Is this another advantage?

\$\endgroup\$
1
\$\begingroup\$

The combined matrix requires decomposition to get the individual elements. E.g., if you want to ask "what is this object's scale, and if it's below 1, double it," then storing everything as a matrix only complicates matters. Storing the individual components makes it trivial to efficiently alter the transform, and the recompute the matrix later when necessary.

Animation is one area where this matters. If you want to interpolate between two positions while applying a constant rotation, you will need the decomposed matrix (the individual translation and rotation components) to do it correctly.

\$\endgroup\$
  • \$\begingroup\$ Concerning animation: not true. If animation is done using quaternions then you only need to compose a matrix (from quaternion, translation and scale) when uploading to the shader. \$\endgroup\$ – knight666 Jul 11 '12 at 7:09
  • \$\begingroup\$ That's exactly what I meant, I just phrased it poorly. :) \$\endgroup\$ – Sean Middleditch Jul 12 '12 at 0:04

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.