public class Matrix2f extends Matrix implements java.io.Serializable
Modifier and Type | Field and Description |
---|---|
float |
m00 |
float |
m01 |
float |
m10 |
float |
m11 |
Constructor and Description |
---|
Matrix2f()
Constructor for Matrix2f.
|
Matrix2f(Matrix2f src)
Constructor
|
Modifier and Type | Method and Description |
---|---|
static Matrix2f |
add(Matrix2f left,
Matrix2f right,
Matrix2f dest)
Add two matrices together and place the result in a third matrix.
|
float |
determinant() |
Matrix |
invert()
Invert this matrix
|
static Matrix2f |
invert(Matrix2f src,
Matrix2f dest)
Invert the source matrix and place the result in the destination matrix.
|
Matrix |
load(java.nio.FloatBuffer buf)
Load from a float buffer.
|
Matrix2f |
load(Matrix2f src)
Load from another matrix
|
static Matrix2f |
load(Matrix2f src,
Matrix2f dest)
Copy the source matrix to the destination matrix.
|
Matrix |
loadTranspose(java.nio.FloatBuffer buf)
Load from a float buffer.
|
static Matrix2f |
mul(Matrix2f left,
Matrix2f right,
Matrix2f dest)
Multiply the right matrix by the left and place the result in a third matrix.
|
Matrix |
negate()
Negate this matrix
|
Matrix2f |
negate(Matrix2f dest)
Negate this matrix and stash the result in another matrix.
|
static Matrix2f |
negate(Matrix2f src,
Matrix2f dest)
Negate the source matrix and stash the result in the destination matrix.
|
Matrix |
setIdentity()
Set this matrix to be the identity matrix.
|
static Matrix2f |
setIdentity(Matrix2f src)
Set the source matrix to be the identity matrix.
|
Matrix |
setZero()
Set this matrix to 0.
|
static Matrix2f |
setZero(Matrix2f src) |
Matrix |
store(java.nio.FloatBuffer buf)
Store this matrix in a float buffer.
|
Matrix |
storeTranspose(java.nio.FloatBuffer buf)
Store this matrix in a float buffer.
|
static Matrix2f |
sub(Matrix2f left,
Matrix2f right,
Matrix2f dest)
Subtract the right matrix from the left and place the result in a third matrix.
|
java.lang.String |
toString()
Returns a string representation of this matrix
|
static Vector2f |
transform(Matrix2f left,
Vector2f right,
Vector2f dest)
Transform a Vector by a matrix and return the result in a destination
vector.
|
Matrix |
transpose()
Transpose this matrix
|
Matrix2f |
transpose(Matrix2f dest)
Transpose this matrix and place the result in another matrix.
|
static Matrix2f |
transpose(Matrix2f src,
Matrix2f dest)
Transpose the source matrix and place the result in the destination matrix.
|
public Matrix2f()
public Matrix2f(Matrix2f src)
public Matrix2f load(Matrix2f src)
src
- The source matrixpublic static Matrix2f load(Matrix2f src, Matrix2f dest)
src
- The source matrixdest
- The destination matrix, or null if a new one should be created.public Matrix load(java.nio.FloatBuffer buf)
public Matrix loadTranspose(java.nio.FloatBuffer buf)
loadTranspose
in class Matrix
buf
- A float buffer to read frompublic Matrix store(java.nio.FloatBuffer buf)
public Matrix storeTranspose(java.nio.FloatBuffer buf)
storeTranspose
in class Matrix
buf
- The buffer to store this matrix inpublic static Matrix2f add(Matrix2f left, Matrix2f right, Matrix2f dest)
left
- The left source matrixright
- The right source matrixdest
- The destination matrix, or null if a new one is to be createdpublic static Matrix2f sub(Matrix2f left, Matrix2f right, Matrix2f dest)
left
- The left source matrixright
- The right source matrixdest
- The destination matrix, or null if a new one is to be createdpublic static Matrix2f mul(Matrix2f left, Matrix2f right, Matrix2f dest)
left
- The left source matrixright
- The right source matrixdest
- The destination matrix, or null if a new one is to be createdpublic static Vector2f transform(Matrix2f left, Vector2f right, Vector2f dest)
left
- The left matrixright
- The right vectordest
- The destination vector, or null if a new one is to be createdpublic Matrix transpose()
public Matrix2f transpose(Matrix2f dest)
dest
- The destination matrix or null if a new matrix is to be createdpublic static Matrix2f transpose(Matrix2f src, Matrix2f dest)
src
- The source matrix or null if a new matrix is to be createddest
- The destination matrix or null if a new matrix is to be createdpublic Matrix invert()
public static Matrix2f invert(Matrix2f src, Matrix2f dest)
src
- The source matrix to be inverteddest
- The destination matrix or null if a new matrix is to be createdpublic java.lang.String toString()
toString
in class java.lang.Object
public Matrix2f negate(Matrix2f dest)
dest
- The destination matrix, or null if a new matrix is to be createdpublic static Matrix2f negate(Matrix2f src, Matrix2f dest)
src
- The source matrix to be negateddest
- The destination matrix, or null if a new matrix is to be createdpublic Matrix setIdentity()
setIdentity
in class Matrix
public static Matrix2f setIdentity(Matrix2f src)
src
- The matrix to set to the identity.public Matrix setZero()
public float determinant()
determinant
in class Matrix
Copyright © 2002-2009 lwjgl.org. All Rights Reserved.