Matrix3

THREE.Matrix3
class Matrix3(n11: UndefOr[Double], n12: UndefOr[Double], n13: UndefOr[Double], n21: UndefOr[Double], n22: UndefOr[Double], n23: UndefOr[Double], n31: UndefOr[Double], n32: UndefOr[Double], n33: UndefOr[Double]) extends Object

Represents a 3x3 matrix in Three.js.

The constructor and set method take arguments in row-major order, while internally they are stored in the elements array in column-major order.

Attributes

Graph
Supertypes
class Object
trait Any
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

override def clone(): Matrix3

Returns a clone of this matrix

Returns a clone of this matrix

Attributes

Definition Classes
Object
def copy(m: Matrix3): this.type

Copies the values from another matrix to this one

Copies the values from another matrix to this one

Attributes

def determinant(): Double

Computes and returns the determinant of this matrix

Computes and returns the determinant of this matrix

Attributes

def equals(matrix: Matrix3): Boolean

Tests if this matrix equals another matrix

Tests if this matrix equals another matrix

Attributes

def extractBasis(xAxis: Vector3, yAxis: Vector3, zAxis: Vector3): this.type

Extracts the basis of this matrix into the three axis vectors provided

Extracts the basis of this matrix into the three axis vectors provided

Attributes

def fromArray(array: Array[Double], offset: Double): this.type

Sets the elements of this matrix from an array

Sets the elements of this matrix from an array

Attributes

def getNormalMatrix(matrix4: Matrix4): this.type

Computes the normal matrix which is the inverse transpose of the upper left 3x3 portion of a 4x4 matrix

Computes the normal matrix which is the inverse transpose of the upper left 3x3 portion of a 4x4 matrix

Attributes

def identity(): this.type

Sets this matrix to the identity matrix

Sets this matrix to the identity matrix

Attributes

def invert(): this.type

Inverts this matrix

Inverts this matrix

Attributes

def makeRotation(theta: Double): this.type

Sets this matrix as a 2D rotational transformation

Sets this matrix as a 2D rotational transformation

Attributes

def makeScale(x: Double, y: Double): this.type

Sets this matrix as a 2D scale transform

Sets this matrix as a 2D scale transform

Attributes

def makeTranslation(x: Double | Vector2, y: UndefOr[Double]): this.type

Sets this matrix as a 2D translation transform

Sets this matrix as a 2D translation transform

Attributes

def multiply(m: Matrix3): this.type

Post-multiplies this matrix by another matrix

Post-multiplies this matrix by another matrix

Attributes

def multiplyMatrices(a: Matrix3, b: Matrix3): this.type

Multiplies two matrices and stores the result in this matrix

Multiplies two matrices and stores the result in this matrix

Attributes

def multiplyScalar(s: Double): this.type

Multiplies every component of the matrix by a scalar

Multiplies every component of the matrix by a scalar

Attributes

def premultiply(m: Matrix3): this.type

Pre-multiplies this matrix by another matrix

Pre-multiplies this matrix by another matrix

Attributes

def rotate(theta: Double): this.type

Rotates this matrix by the given angle

Rotates this matrix by the given angle

Attributes

def scale(sx: Double, sy: Double): this.type

Scales this matrix with the given scalar values

Scales this matrix with the given scalar values

Attributes

def set(n11: Double, n12: Double, n13: Double, n21: Double, n22: Double, n23: Double, n31: Double, n32: Double, n33: Double): this.type

Sets the elements of the matrix in row-major order

Sets the elements of the matrix in row-major order

Attributes

def setFromMatrix4(m: Matrix4): this.type

Sets this matrix to the upper 3x3 matrix of the given 4x4 matrix

Sets this matrix to the upper 3x3 matrix of the given 4x4 matrix

Attributes

def setUvTransform(tx: Double, ty: Double, sx: Double, sy: Double, rotation: Double, cx: Double, cy: Double): this.type

Sets the UV transform matrix from offset, repeat, rotation, and center

Sets the UV transform matrix from offset, repeat, rotation, and center

Attributes

def toArray(array: Array[Double], offset: Double): Array[Double]

Returns the elements of this matrix in an array

Returns the elements of this matrix in an array

Attributes

def translate(tx: Double, ty: Double): this.type

Translates this matrix by the given scalar values

Translates this matrix by the given scalar values

Attributes

def transpose(): this.type

Transposes this matrix in place

Transposes this matrix in place

Attributes

def transposeIntoArray(r: Array[Double]): this.type

Transposes this matrix into the supplied array

Transposes this matrix into the supplied array

Attributes

Inherited methods

def hasOwnProperty(v: String): Boolean

Attributes

Inherited from:
Object
def isPrototypeOf(v: Object): Boolean

Attributes

Inherited from:
Object
def propertyIsEnumerable(v: String): Boolean

Attributes

Inherited from:
Object
def toLocaleString(): String

Attributes

Inherited from:
Object
def valueOf(): Any

Attributes

Inherited from:
Object

Concrete fields

val elements: Array[Double]

A column-major list of matrix values

A column-major list of matrix values

Attributes

val isMatrix3: Boolean

Flag that can be used for type testing

Flag that can be used for type testing

Attributes