- class M22d
2x2 double precision floating point transformation matrix.
- M22d()
Default constructor: initialize to identity
1 00 1
- M22d(a: double)
Initialize to scalar constant
a aa a
- M22d(a: double, b: double, c: double, d: double)
Construct from given scalar values:
a bc d
- determinant() double
Determinant
- equalWithAbsError(m: M22d, e: double) bool
Compare two matrices and test if they are “approximately equal”: @return True if the coefficients of this and m are the same with an absolute error of no more than e, i.e., for all i, j:
abs (this[i][j] - m[i][j]) <= e
- equalWithRelError(m: M22d, e: double) bool
Compare two matrices and test if they are “approximately equal”: @return True if the coefficients of this and m are the same with a relative error of no more than e, i.e., for all i, j:
abs (this[i] - v[i][j]) <= e * abs (this[i][j])
- fastMinor(r0: int, r1: int, c0: int, c1: int) double
Build a minor using the specified rows and columns
- invert()
Invert in place using the determinant
- negate()
Component-wise multiplication by -1
- makeIdentity()
Set to the identity matrix
- rotate(r: double)
Rotate the matrix by r (in radians)
- setRotation(r: double)
Set matrix to rotation by r (in radians)
- setScale(s: double)
Set matrix to scale by given uniform factor
- transpose()
Transpose