TM Property of taccgl
Short Description: Transformation Matrix
TM holds a 4x4 transformation matrix using homogenous
coordinates that can be used to translate the position of
transitions selected with useTM.
TM is stored as a 4x4 Matrix, however unlike normally,
this matrix is stored in column major order.
Initially TM holds the identity matrix. It
can be read or written anytime and should be written with
the setTM or setTMorth method.
Changing TM however only has an effect on transitions
that explicitly use useTM. On the other hand the
transformation matrix is applied simultanously on all transitions
that use useTM. There is just one global
transformation matrix for all these
transitions. Changing TM is much faster than changing
each transition individually, so TM is usually used to
animate all or at least many objects/transitions of a scene.
setTM Library Method
Short Description: Set Transformation Matrix
Signature: taccgl.setTM (tm)
Class: taccgl Class
sets the transformation matrix to the specified argument tm and also
In the following example the id=para element is moved using the TM
while at the same time the id=testimg stays unaffected, since useTM
is applied to the id=para only. In the second example below, both elements are affected.
| var a=taccgl.actor("testimg").to (0,1000,0).start();|
| var a=taccgl.actor("testimg").to (0,1000,0).useTM().start();|
TM_1T Property of taccgl
Short Description: Inverse Transformation Matrix
TM_1T holds the transposed inverse of the transformation matrix as 3x3 matrix in column major
order. It should always be set with the setTM or setTMorth method.
setTMorth Library Method
Short Description: Set orthogonal Transformation Matrix
Signature: taccgl.setTMorth (tm)
Class: taccgl Class
Works like setTM and sets the TM and TM_1T properties,
but may only be used for an orthogonal matrix tm.
This functions is slightly faster, because it avoids calculating the inverse matrix.