Class: Matrix2d

me. Matrix2d

new Matrix2d(mat2d)

a Matrix2d Object.
the identity matrix and parameters position :
Parameters:
Name Type Argument Description
mat2d me.Matrix2d <optional>
An instance of me.Matrix2d to copy from
arguments... Array.<Number> <optional>
Matrix elements. See me.Matrix2d.set
Source:
matrix2.js, line 19

Extends

Methods

<static> clone() → {me.Matrix2d}

Clone the Matrix
Source:
matrix2.js, line 380
Returns:
Type
me.Matrix2d

<static> copy(m) → {me.Matrix2d}

Copies over the values from another me.Matrix2d.
Parameters:
Name Type Description
m me.Matrix2d the matrix object to copy from
Source:
matrix2.js, line 100
Returns:
Reference to this object for method chaining
Type
me.Matrix2d

<static> identity() → {me.Matrix2d}

reset the transformation matrix to the identity matrix (no transformation).
the identity matrix and parameters position :
Source:
matrix2.js, line 38
Returns:
Reference to this object for method chaining
Type
me.Matrix2d

<static> invert() → {me.Matrix2d}

invert this matrix, causing it to apply the opposite transformation.
Source:
matrix2.js, line 168
Returns:
Reference to this object for method chaining
Type
me.Matrix2d

<static> isIdentity() → {Boolean}

returns true if the matrix is an identity matrix.
Source:
matrix2.js, line 357
Returns:
Type
Boolean

<static> multiply(b) → {me.Matrix2d}

multiply both matrix
Parameters:
Name Type Description
b me.Matrix2d Other matrix
Source:
matrix2.js, line 113
Returns:
Reference to this object for method chaining
Type
me.Matrix2d

<static> multiplyVector(vector) → {me.Vector2d}

Transforms the given vector according to this matrix.
Parameters:
Name Type Description
vector me.Vector2d the vector object to be transformed
Source:
matrix2.js, line 203
Returns:
result vector object. Useful for chaining method calls.
Type
me.Vector2d

<static> multiplyVector(vector) → {me.Vector2d}

Transforms the given vector using the inverted current matrix.
Parameters:
Name Type Description
vector me.Vector2d the vector object to be transformed
Source:
matrix2.js, line 222
Returns:
result vector object. Useful for chaining method calls.
Type
me.Vector2d

<static> rotate(angle) → {me.Matrix2d}

rotate the matrix (counter-clockwise) by the specified angle (in radians).
Parameters:
Name Type Description
angle Number Rotation angle in radians.
Source:
matrix2.js, line 301
Returns:
Reference to this object for method chaining
Type
me.Matrix2d

<static> scale(x, y) → {me.Matrix2d}

scale the matrix
Parameters:
Name Type Argument Default Description
x Number a number representing the abscissa of the scaling vector.
y Number <optional>
x a number representing the ordinate of the scaling vector.
Source:
matrix2.js, line 243
Returns:
Reference to this object for method chaining
Type
me.Matrix2d

<static> scaleV(vector) → {me.Matrix2d}

adds a 2D scaling transformation.
Parameters:
Name Type Description
vector me.Vector2d scaling vector
Source:
matrix2.js, line 265
Returns:
Reference to this object for method chaining
Type
me.Matrix2d

<static> scaleX(x) → {me.Matrix2d}

specifies a 2D scale operation using the [sx, 1] scaling vector
Parameters:
Name Type Description
x Number x scaling vector
Source:
matrix2.js, line 277
Returns:
Reference to this object for method chaining
Type
me.Matrix2d

<static> scaleY(y) → {me.Matrix2d}

specifies a 2D scale operation using the [1,sy] scaling vector
Parameters:
Name Type Description
y Number y scaling vector
Source:
matrix2.js, line 289
Returns:
Reference to this object for method chaining
Type
me.Matrix2d

<static> setTransform(a, b, c, d, e, f, g, h, i) → {me.Matrix2d}

set the matrix to the specified value
Parameters:
Name Type Argument Default Description
a Number
b Number
c Number
d Number
e Number
f Number
g Number <optional>
0
h Number <optional>
0
i Number <optional>
1
Source:
matrix2.js, line 56
Returns:
Reference to this object for method chaining
Type
me.Matrix2d

<static> toString() → {String}

convert the object to a string representation
Source:
matrix2.js, line 391
Returns:
Type
String

<static> translate(x, y) → {me.Matrix2d}

translate the matrix position on the horizontal and vertical axis
Parameters:
Name Type Description
x Number the x coordindates to translate the matrix by
y Number the y coordindates to translate the matrix by
Source:
matrix2.js, line 327
Returns:
Reference to this object for method chaining
Type
me.Matrix2d

<static> translateV(v) → {me.Matrix2d}

translate the matrix by a vector on the horizontal and vertical axis
Parameters:
Name Type Description
v me.Vector2d the vector to translate the matrix by
Source:
matrix2.js, line 345
Returns:
Reference to this object for method chaining
Type
me.Matrix2d

<static> transpose() → {me.Matrix2d}

Transpose the value of this matrix.
Source:
matrix2.js, line 145
Returns:
Reference to this object for method chaining
Type
me.Matrix2d
Copyright © 2011 - 2017, Olivier Biot, Jason Oster, Aaron McLeod
Documentation generated by JSDoc 3.4.0 on 2017-02-28T11:37:41+08:00 using the DocStrap template modified by codename-.