DAZ Script |
---|
DzMatrix4 ( Boolean initIdentity=false ) |
DzMatrix4 ( Number m11, Number m21, Number m31, Number m41, Number m12, Number m22, Number m32, Number m42, Number m13, Number m23, Number m33, Number m43, Number m14, Number m24, Number m34, Number m44 ) |
DzMatrix4 ( DzVec3 xAxis, DzVec3 yAxis, DzVec3 zAxis ) |
DzMatrix4 ( DzQuat rot ) |
DzMatrix4 ( DzMatrix4 mat ) |
DAZ Script | |
---|---|
DzMatrix4 | inverse () |
void | invert () |
void | makeIdentity () |
DzMatrix3 | matrix3 () |
DzMatrix4 | multiply ( DzMatrix4 mat ) |
DzVec3 | multMatrixVec ( DzVec3 vec ) |
DzVec3 | multVecMatrix ( DzVec3 vec ) |
Boolean | orthogonal () |
void | preScale ( Number scale ) |
void | preScale ( DzVec3 vec ) |
void | preScale ( Number scale, DzVec3 direction ) |
void | preShearXY ( Number xShear, Number yShear ) |
void | preShearXZ ( Number xShear, Number zShear ) |
void | preShearYZ ( Number yShear, Number zShear ) |
void | preTranslate ( DzVec3 vec ) |
void | rotate ( DzQuat rot ) |
void | rotateX ( Number radians ) |
void | rotateY ( Number radians ) |
void | rotateZ ( Number radians ) |
DzVec3 | row ( Number i ) |
void | scale ( DzVec3 vec ) |
void | scale ( Number scale ) |
void | scale ( Number scale, DzVec3 direction ) |
void | setRow ( Number i, DzVec3 vec ) |
void | setTrans ( DzVec3 vec ) |
void | shearXY ( Number xShear, Number yShear ) |
void | shearXZ ( Number xShear, Number zShear ) |
void | shearYZ ( Number yShear, Number zShear ) |
Number | trace () |
void | translate ( DzVec3 vec ) |
DzMatrix4 | transpose () |
A transformation matrix consisting of 4 rows and 4 columns.
Whether or not the matrix is identity
The value of the matrix at [1, 1]
The value of the matrix at [1, 2]
The value of the matrix at [1, 3]
The value of the matrix at [1, 4]
The value of the matrix at [2, 1]
The value of the matrix at [2, 2]
The value of the matrix at [2, 3]
The value of the matrix at [2, 4]
The value of the matrix at [3, 1]
The value of the matrix at [3, 2]
The value of the matrix at [3, 3]
The value of the matrix at [3, 4]
The value of the matrix at [4, 1]
The value of the matrix at [4, 2]
The value of the matrix at [4, 3]
The value of the matrix at [4, 4]
DzMatrix4( Boolean initIdentity=false )
Default Constructor.
Parameter(s):
DzMatrix4( Number m11, Number m21, Number m31, Number m41, Number m12, Number m22, Number m32, Number m42, Number m13, Number m23, Number m33, Number m43, Number m14, Number m24, Number m34, Number m44 )
Constructs a 4×4 matrix from 16 elements in “Column Major” order.
Parameter(s):
Example:
// Create a new 4x4 matrix var mtx4 = new DzMatrix4( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 ); // Print the input sequence, for comparison print( 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0 ); // Print elements of the matrix in column major order print( mtx4.m11, mtx4.m21, mtx4.m31, mtx4.m41, mtx4.m12, mtx4.m22, mtx4.m32, mtx4.m42, mtx4.m13, mtx4.m23, mtx4.m33, mtx4.m43, mtx4.m14, mtx4.m24, mtx4.m34, mtx4.m44 );
DzMatrix4( DzVec3 xAxis, DzVec3 yAxis, DzVec3 zAxis )
Constructor from three axes of the rotation coord system. These are assumed to be (but do not have to be if a sheared or warped coord system is desired) to be orthogonal unit vectors.
Since:
Constructs a 4×4 matrix from a quaternion. Initializes the matrix to the given rotation.
Parameter(s):
Since:
DzMatrix4( DzMatrix4 mat )
Copy Constructor.
Parameter(s):
DzMatrix4 : inverse()
Return Value:
void : invert()
Test and choose best inverse for current matrix
Since:
void : makeIdentity()
Sets the matrix to be identity
Return Value:
Since:
DzMatrix4 : multiply( DzMatrix4 mat )
Calculates the multiplication of this matrix by the given matrix.
Parameter(s):
Return Value:
DzVec3 : multMatrixVec( DzVec3 vec )
Multiplies matrix by given column vector, giving column vector result
Parameter(s):
Return Value:
DzVec3 : multVecMatrix( DzVec3 vec )
Multiplies given row vector by matrix, giving row vector result
Parameter(s):
Return Value:
Boolean : orthogonal()
Test for orthogonal 3×3 sub-matrix (orthonormal rows)
Since:
void : preScale( Number scale )
Accumulates a uniform scale by pre-multiplying.
Accumulates a general scale by pre-multiplying.
Parameter(s):
void : preScale( Number scale, DzVec3 direction )
Accumulates a scale along an arbitrary axis by pre-multiplying.
Since:
void : preShearXY( Number xShear, Number yShear )
Shears the matrix along the x and y axis (by pre-multiplying).
Parameter(s):
Since:
void : preShearXZ( Number xShear, Number zShear )
Shears the matrix along the x and z axis (by pre-multiplying).
Parameter(s):
Since:
void : preShearYZ( Number yShear, Number zShear )
Shears the matrix along the y and z axis (by pre-multiplying).
Parameter(s):
Since:
void : preTranslate( DzVec3 vec )
Accumulate a translation by pre-multiplying.
Parameter(s):
Accumulate rotation (by post-multiplying).
void : rotateX( Number radians )
Accumulate rotation around the X axis (by post-multiplying).
void : rotateY( Number radians )
Accumulate rotation around the Y axis (by post-multiplying).
void : rotateZ( Number radians )
Accumulate rotation around the Z axis (by post-multiplying).
Return Value:
Since:
Accumulates a general scale (by post-multiplying).
Accumulates a uniform scale (by post-multiplying).
void : scale( Number scale, DzVec3 direction )
Accumulates a scale along an arbitrary axis (by post-multiplying).
Since:
void : setRow( Number i, DzVec3 vec )
TODO: Add description.
Sets matrix to translate by given vector, leaving rotation as is
Parameter(s):
void : shearXY( Number xShear, Number yShear )
Shears the matrix along the x and y axis (by post-multiplying).
Parameter(s):
Since:
void : shearXZ( Number xShear, Number zShear )
Shears the matrix along the x and z axis (by post-multiplying).
Parameter(s):
Since:
void : shearYZ( Number yShear, Number zShear )
Shears the matrix along the y and z axis (by post-multiplying).
Parameter(s):
Since:
Return Value:
Since:
void : translate( DzVec3 vec )
Accumulate a translation (by post-multiplying).
Parameter(s):
DzMatrix4 : transpose()
Return Value:
Since: