Package org.joml
Class Matrix3f
java.lang.Object
org.joml.Matrix3f
- All Implemented Interfaces:
java.io.Externalizable,java.io.Serializable,Matrix3fc
public class Matrix3f extends java.lang.Object implements java.io.Externalizable, Matrix3fc
- See Also:
- Serialized Form
-
Field Summary
-
Constructor Summary
Constructors Constructor Description Matrix3f()Matrix3f(float m00, float m01, float m02, float m10, float m11, float m12, float m20, float m21, float m22)Matrix3f(java.nio.FloatBuffer buffer)Matrix3f(Matrix3fc mat)Matrix3f(Matrix4fc mat)Matrix3f(Vector3fc col0, Vector3fc col1, Vector3fc col2) -
Method Summary
Modifier and Type Method Description Matrix3fadd(Matrix3fc other)Matrix3fadd(Matrix3fc other, Matrix3f dest)floatdeterminant()booleanequals(java.lang.Object obj)float[]get(float[] arr)float[]get(float[] arr, int offset)java.nio.ByteBufferget(int index, java.nio.ByteBuffer buffer)java.nio.FloatBufferget(int index, java.nio.FloatBuffer buffer)java.nio.ByteBufferget(java.nio.ByteBuffer buffer)java.nio.FloatBufferget(java.nio.FloatBuffer buffer)Matrix3fget(Matrix3f dest)Matrix4fget(Matrix4f dest)Vector3fgetColumn(int column, Vector3f dest)Vector3fgetEulerAnglesZYX(Vector3f dest)QuaterniondgetNormalizedRotation(Quaterniond dest)QuaternionfgetNormalizedRotation(Quaternionf dest)AxisAngle4fgetRotation(AxisAngle4f dest)Vector3fgetRow(int row, Vector3f dest)Vector3fgetScale(Vector3f dest)java.nio.ByteBuffergetTransposed(int index, java.nio.ByteBuffer buffer)java.nio.FloatBuffergetTransposed(int index, java.nio.FloatBuffer buffer)java.nio.ByteBuffergetTransposed(java.nio.ByteBuffer buffer)java.nio.FloatBuffergetTransposed(java.nio.FloatBuffer buffer)QuaterniondgetUnnormalizedRotation(Quaterniond dest)QuaternionfgetUnnormalizedRotation(Quaternionf dest)inthashCode()Matrix3fidentity()Matrix3finvert()Matrix3finvert(Matrix3f dest)Matrix3flerp(Matrix3fc other, float t)Matrix3flerp(Matrix3fc other, float t, Matrix3f dest)Matrix3flookAlong(float dirX, float dirY, float dirZ, float upX, float upY, float upZ)Matrix3flookAlong(float dirX, float dirY, float dirZ, float upX, float upY, float upZ, Matrix3f dest)Matrix3flookAlong(Vector3fc dir, Vector3fc up)Matrix3flookAlong(Vector3fc dir, Vector3fc up, Matrix3f dest)floatm00()Matrix3fm00(float m00)floatm01()Matrix3fm01(float m01)floatm02()Matrix3fm02(float m02)floatm10()Matrix3fm10(float m10)floatm11()Matrix3fm11(float m11)floatm12()Matrix3fm12(float m12)floatm20()Matrix3fm20(float m20)floatm21()Matrix3fm21(float m21)floatm22()Matrix3fm22(float m22)Matrix3fmul(Matrix3fc right)Matrix3fmul(Matrix3fc right, Matrix3f dest)Matrix3fmulComponentWise(Matrix3fc other)Matrix3fmulComponentWise(Matrix3fc other, Matrix3f dest)Matrix3fnormal()Matrix3fnormal(Matrix3f dest)Vector3fnormalizedPositiveX(Vector3f dir)Vector3fnormalizedPositiveY(Vector3f dir)Vector3fnormalizedPositiveZ(Vector3f dir)Vector3fpositiveX(Vector3f dir)Vector3fpositiveY(Vector3f dir)Vector3fpositiveZ(Vector3f dir)voidreadExternal(java.io.ObjectInput in)Matrix3frotate(float ang, float x, float y, float z)Matrix3frotate(float ang, float x, float y, float z, Matrix3f dest)Matrix3frotate(float angle, Vector3fc axis)Matrix3frotate(float angle, Vector3fc axis, Matrix3f dest)Matrix3frotate(AxisAngle4f axisAngle)Matrix3frotate(AxisAngle4f axisAngle, Matrix3f dest)Matrix3frotate(Quaternionfc quat)Matrix3frotate(Quaternionfc quat, Matrix3f dest)Matrix3frotateLocal(float ang, float x, float y, float z)Matrix3frotateLocal(float ang, float x, float y, float z, Matrix3f dest)Matrix3frotateLocal(Quaternionfc quat)Matrix3frotateLocal(Quaternionfc quat, Matrix3f dest)Matrix3frotateTowards(float dirX, float dirY, float dirZ, float upX, float upY, float upZ)Matrix3frotateTowards(float dirX, float dirY, float dirZ, float upX, float upY, float upZ, Matrix3f dest)Matrix3frotateTowards(Vector3fc direction, Vector3fc up)Matrix3frotateTowards(Vector3fc direction, Vector3fc up, Matrix3f dest)Matrix3frotateX(float ang)Matrix3frotateX(float ang, Matrix3f dest)Matrix3frotateXYZ(float angleX, float angleY, float angleZ)Matrix3frotateXYZ(float angleX, float angleY, float angleZ, Matrix3f dest)Matrix3frotateXYZ(Vector3f angles)Matrix3frotateY(float ang)Matrix3frotateY(float ang, Matrix3f dest)Matrix3frotateYXZ(float angleY, float angleX, float angleZ)Matrix3frotateYXZ(float angleY, float angleX, float angleZ, Matrix3f dest)Matrix3frotateYXZ(Vector3f angles)Matrix3frotateZ(float ang)Matrix3frotateZ(float ang, Matrix3f dest)Matrix3frotateZYX(float angleZ, float angleY, float angleX)Matrix3frotateZYX(float angleZ, float angleY, float angleX, Matrix3f dest)Matrix3frotateZYX(Vector3f angles)Matrix3frotation(float angle, float x, float y, float z)Matrix3frotation(float angle, Vector3fc axis)Matrix3frotation(AxisAngle4f axisAngle)Matrix3frotation(Quaternionfc quat)Matrix3frotationTowards(float dirX, float dirY, float dirZ, float upX, float upY, float upZ)Matrix3frotationTowards(Vector3fc dir, Vector3fc up)Matrix3frotationX(float ang)Matrix3frotationXYZ(float angleX, float angleY, float angleZ)Matrix3frotationY(float ang)Matrix3frotationYXZ(float angleY, float angleX, float angleZ)Matrix3frotationZ(float ang)Matrix3frotationZYX(float angleZ, float angleY, float angleX)Matrix3fscale(float xyz)Matrix3fscale(float x, float y, float z)Matrix3fscale(float x, float y, float z, Matrix3f dest)Matrix3fscale(float xyz, Matrix3f dest)Matrix3fscale(Vector3fc xyz)Matrix3fscale(Vector3fc xyz, Matrix3f dest)Matrix3fscaleLocal(float x, float y, float z)Matrix3fscaleLocal(float x, float y, float z, Matrix3f dest)Matrix3fscaling(float factor)Matrix3fscaling(float x, float y, float z)Matrix3fscaling(Vector3fc xyz)Matrix3fset(float[] m)Matrix3fset(float m00, float m01, float m02, float m10, float m11, float m12, float m20, float m21, float m22)Matrix3fset(java.nio.ByteBuffer buffer)Matrix3fset(java.nio.FloatBuffer buffer)Matrix3fset(AxisAngle4d axisAngle)Matrix3fset(AxisAngle4f axisAngle)Matrix3fset(Matrix3fc m)Matrix3fset(Matrix4fc mat)Matrix3fset(Quaterniondc q)Matrix3fset(Quaternionfc q)Matrix3fset(Vector3fc col0, Vector3fc col1, Vector3fc col2)Matrix3fsetColumn(int column, Vector3fc src)Matrix3fsetLookAlong(float dirX, float dirY, float dirZ, float upX, float upY, float upZ)Matrix3fsetLookAlong(Vector3fc dir, Vector3fc up)Matrix3fsetRow(int row, Vector3fc src)Matrix3fsetSkewSymmetric(float a, float b, float c)Matrix3fsub(Matrix3fc subtrahend)Matrix3fsub(Matrix3fc subtrahend, Matrix3f dest)Matrix3fswap(Matrix3f other)Matrix3fctoImmutable()java.lang.StringtoString()java.lang.StringtoString(java.text.NumberFormat formatter)Vector3ftransform(float x, float y, float z, Vector3f dest)Vector3ftransform(Vector3f v)Vector3ftransform(Vector3fc v, Vector3f dest)Matrix3ftranspose()Matrix3ftranspose(Matrix3f dest)voidwriteExternal(java.io.ObjectOutput out)Matrix3fzero()Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Field Details
-
m00
public float m00 -
m01
public float m01 -
m02
public float m02 -
m10
public float m10 -
m11
public float m11 -
m12
public float m12 -
m20
public float m20 -
m21
public float m21 -
m22
public float m22
-
-
Constructor Details
-
Matrix3f
public Matrix3f() -
Matrix3f
-
Matrix3f
-
Matrix3f
public Matrix3f(float m00, float m01, float m02, float m10, float m11, float m12, float m20, float m21, float m22) -
Matrix3f
public Matrix3f(java.nio.FloatBuffer buffer) -
Matrix3f
-
-
Method Details
-
m00
public float m00() -
m01
public float m01() -
m02
public float m02() -
m10
public float m10() -
m11
public float m11() -
m12
public float m12() -
m20
public float m20() -
m21
public float m21() -
m22
public float m22() -
m00
-
m01
-
m02
-
m10
-
m11
-
m12
-
m20
-
m21
-
m22
-
set
-
set
-
set
-
set
-
set
-
set
-
mul
-
mul
-
set
public Matrix3f set(float m00, float m01, float m02, float m10, float m11, float m12, float m20, float m21, float m22) -
set
-
set
-
determinant
public float determinant()- Specified by:
determinantin interfaceMatrix3fc
-
invert
-
invert
-
transpose
-
transpose
-
toString
public java.lang.String toString()- Overrides:
toStringin classjava.lang.Object
-
toString
public java.lang.String toString(java.text.NumberFormat formatter) -
get
-
get
-
getRotation
- Specified by:
getRotationin interfaceMatrix3fc
-
getUnnormalizedRotation
- Specified by:
getUnnormalizedRotationin interfaceMatrix3fc
-
getNormalizedRotation
- Specified by:
getNormalizedRotationin interfaceMatrix3fc
-
getUnnormalizedRotation
- Specified by:
getUnnormalizedRotationin interfaceMatrix3fc
-
getNormalizedRotation
- Specified by:
getNormalizedRotationin interfaceMatrix3fc
-
get
public java.nio.FloatBuffer get(java.nio.FloatBuffer buffer) -
get
public java.nio.FloatBuffer get(int index, java.nio.FloatBuffer buffer) -
get
public java.nio.ByteBuffer get(java.nio.ByteBuffer buffer) -
get
public java.nio.ByteBuffer get(int index, java.nio.ByteBuffer buffer) -
getTransposed
public java.nio.FloatBuffer getTransposed(java.nio.FloatBuffer buffer)- Specified by:
getTransposedin interfaceMatrix3fc
-
getTransposed
public java.nio.FloatBuffer getTransposed(int index, java.nio.FloatBuffer buffer)- Specified by:
getTransposedin interfaceMatrix3fc
-
getTransposed
public java.nio.ByteBuffer getTransposed(java.nio.ByteBuffer buffer)- Specified by:
getTransposedin interfaceMatrix3fc
-
getTransposed
public java.nio.ByteBuffer getTransposed(int index, java.nio.ByteBuffer buffer)- Specified by:
getTransposedin interfaceMatrix3fc
-
get
public float[] get(float[] arr, int offset) -
get
public float[] get(float[] arr) -
set
-
set
-
zero
-
identity
-
scale
-
scale
-
scale
-
scale
-
scale
-
scale
-
scaleLocal
- Specified by:
scaleLocalin interfaceMatrix3fc
-
scaleLocal
-
scaling
-
scaling
-
scaling
-
rotation
-
rotation
-
rotation
-
rotationX
-
rotationY
-
rotationZ
-
rotationXYZ
-
rotationZYX
-
rotationYXZ
-
rotation
-
transform
-
transform
-
transform
-
writeExternal
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException- Specified by:
writeExternalin interfacejava.io.Externalizable- Throws:
java.io.IOException
-
readExternal
public void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException- Specified by:
readExternalin interfacejava.io.Externalizable- Throws:
java.io.IOExceptionjava.lang.ClassNotFoundException
-
rotateX
-
rotateX
-
rotateY
-
rotateY
-
rotateZ
-
rotateZ
-
rotateXYZ
-
rotateXYZ
-
rotateXYZ
-
rotateZYX
-
rotateZYX
-
rotateZYX
-
rotateYXZ
-
rotateYXZ
-
rotateYXZ
-
rotate
-
rotate
-
rotateLocal
- Specified by:
rotateLocalin interfaceMatrix3fc
-
rotateLocal
-
rotate
-
rotate
-
rotateLocal
- Specified by:
rotateLocalin interfaceMatrix3fc
-
rotateLocal
-
rotate
-
rotate
-
rotate
-
rotate
-
lookAlong
-
lookAlong
-
lookAlong
-
lookAlong
-
setLookAlong
-
setLookAlong
-
getRow
-
setRow
- Throws:
java.lang.IndexOutOfBoundsException
-
getColumn
-
setColumn
- Throws:
java.lang.IndexOutOfBoundsException
-
normal
-
normal
-
getScale
-
positiveZ
-
normalizedPositiveZ
- Specified by:
normalizedPositiveZin interfaceMatrix3fc
-
positiveX
-
normalizedPositiveX
- Specified by:
normalizedPositiveXin interfaceMatrix3fc
-
positiveY
-
normalizedPositiveY
- Specified by:
normalizedPositiveYin interfaceMatrix3fc
-
hashCode
public int hashCode()- Overrides:
hashCodein classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)- Overrides:
equalsin classjava.lang.Object
-
swap
-
add
-
add
-
sub
-
sub
-
mulComponentWise
-
mulComponentWise
- Specified by:
mulComponentWisein interfaceMatrix3fc
-
setSkewSymmetric
-
lerp
-
lerp
-
rotateTowards
- Specified by:
rotateTowardsin interfaceMatrix3fc
-
rotateTowards
-
rotateTowards
-
rotateTowards
public Matrix3f rotateTowards(float dirX, float dirY, float dirZ, float upX, float upY, float upZ, Matrix3f dest)- Specified by:
rotateTowardsin interfaceMatrix3fc
-
rotationTowards
-
rotationTowards
public Matrix3f rotationTowards(float dirX, float dirY, float dirZ, float upX, float upY, float upZ) -
getEulerAnglesZYX
- Specified by:
getEulerAnglesZYXin interfaceMatrix3fc
-
toImmutable
-