QMedia
![]() |
![]() ![]() |
QM_RotateMatrix(matrixRec; numDegrees; anchorH; anchorV):error | |||
![]() |
matrixRec | Array real | Matrix record |
![]() |
numDegrees | Real | Number of degrees |
![]() |
anchorH | Real | Horizontal coordinate of the anchor point |
![]() |
anchorV | Real | Vertical coordinate of the anchor point |
![]() |
error | Longint | Error result |
Adds a rotation transformation to a matrix record.
Parameter matrixRec specifies the matrix. It must be declared as a 3 x 3 array of reals. QMedia updates and returns the contents matrixRec with the specified rotation operation.
Parameter numDegrees specifies the number of degrees of the rotation operation.
Parameters anchorH and anchorV specify the horizontal and vertical coordinates of the anchor point.
Example
`Rotate track ID $trackID of movie $movie by 30 degrees around its center ARRAY REAL($matrix;3;3) $err:=QM_SetIdentityMatrix ($matrix) C_REAL($trachWidth;$trackHeight) $err:=QM_GetTrackDimensions ($movie;$trackID;$trachWidth;$trackHeight) C_REAL($degrees;$hAnchor;$vAnchor) $degrees:=30 `Rotate 30 degrees $hAnchor:=$trachWidth/2 `Anchor at center of track $vAnchor:=$trackHeight/2 $err:=QM_RotateMatrix ($matrix;$degrees;$hAnchor;$vAnchor) $err:=QM_SetTrackMatrix ($movie;$trackID;$matrix) |
Related commands
QM_SetIdentityMatrix | Sets the contents of a matrix record to the identity matrix. |
QM_TranslateMatrix | Adds a translation transformation to a matrix record. |
QM_ScaleMatrix | Adds a scaling transformation to a matrix record. |
QM_SkewMatrix | Adds a skew transformation to a matrix record. |
QM_ConcatMatrix | Concatenates two matrices. |
QM_SetTrackMatrix | Changes the track's transormation matrix. |
QM_GetTrackMatrix | Returns the track's transormation matrix. |