Class: Matrix4

Matrix4

new Matrix4()

Creates new matrix4 as identity matrix
Source:

Methods

apply(lhs)

Applies transformation matrix
Parameters:
Name Type Description
lhs Ayce.Matrix4
Source:

applyRotation(degrees, axis, pivotPoint)

Applies rotation to matrix
Parameters:
Name Type Description
degrees Number
axis Ayce.Vector3
pivotPoint Ayce.Vector3
Source:

applyScale(xScale, yScale, zScale)

Applies scaling to matrix
Parameters:
Name Type Description
xScale Number
yScale Number
zScale Number
Source:

applyTranslation(x, y, z)

Applies translation to matrix
Parameters:
Name Type Description
x Number
y Number
z Number
Source:

copy() → {Ayce.Matrix4}

Creates a copy of the matrix
Source:
Returns:
m
Type
Ayce.Matrix4

copyToMatrix(from, to)

Copies values from one matrix to another
Parameters:
Name Type Description
from Ayce.Matrix4
to Ayce.Matrix4
Source:

getAxisRotation(x, y, z, degrees, toMatrix) → {Ayce.Matrix4}

TODO: Description
Parameters:
Name Type Description
x Number
y Number
z Number
degrees Number
toMatrix Boolean
Source:
Returns:
m
Type
Ayce.Matrix4

getDeterminant() → {Number}

Returns Determinant of matrix
Source:
Returns:
determinant
Type
Number

getMatrix3(toMatrix) → {Ayce.Matrix3}

TODO: Converts Ayce.Matrix4 to Ayce.Matrix3
Parameters:
Name Type Description
toMatrix Ayce.Matrix4
Source:
Returns:
m3
Type
Ayce.Matrix3

identity()

Description
Source:

invert() → {Boolean}

Inverts the matrix
Source:
Returns:
invertable
Type
Boolean

transformVector(vector) → {Ayce.Vector3}

Applies matrix to vector
Parameters:
Name Type Description
vector Ayce.Vector3
Source:
Returns:
vector
Type
Ayce.Vector3

transpose()

Transposes the matrix
Source:

(static) makeOrthoPerspective(left, right, top, bottom, near, far) → {Ayce.Matrix4}

Creates orthographic perspective matrix
Parameters:
Name Type Description
left Number
right Number
top Number
bottom Number
near Number
far Number
Source:
Returns:
m
Type
Ayce.Matrix4

(static) makePerspective(fieldOfView, aspect, near, far) → {Ayce.Matrix4}

Creates perspective matrix for viewing frustum
Parameters:
Name Type Description
fieldOfView Number
aspect Number
near Number
far Number
Source:
Returns:
m
Type
Ayce.Matrix4

(static) makeVRPerspective(VRfov, zNear, zFar) → {Ayce.Matrix4}

Creates perspective matrix for use with the Oculus Rift
Parameters:
Name Type Description
VRfov Number
zNear Number
zFar Number
Source:
Returns:
m
Type
Ayce.Matrix4