Matrix4 implements Cloneable, Savable, Externalizable, ReadOnlyMatrix4, Poolable { public Matrix4 fromAngleAxis(final double angle, final ReadOnlyVector3 axis) { final Vector3 normAxis = Vector3.fetchTempInstance(); axis.normalize(normAxis); fromAngleNormalAxis(angle, normAxis); Vector3.releaseTempInstance(normAxis); return this; } Matrix4();  Matrix4(final double m00, final double m01, final double m02, final double m03, final double m10,
    final double m11, final double m12, final double m13, final double m20, final double m21, final double m22,
    final double m23, final double m30, final double m31, final double m32, final double m33);  Matrix4(final ReadOnlyMatrix4 source); @Override double getValue(final int row, final int column); @Override float getValuef(final int row, final int column); @Override double getM00(); @Override double getM01(); @Override double getM02(); @Override double getM03(); @Override double getM10(); @Override double getM11(); @Override double getM12(); @Override double getM13(); @Override double getM20(); @Override double getM21(); @Override double getM22(); @Override double getM23(); @Override double getM30(); @Override double getM31(); @Override double getM32(); @Override double getM33(); void setM00(final double m00); void setM01(final double m01); void setM02(final double m02); void setM03(final double m03); void setM10(final double m10); void setM11(final double m11); void setM12(final double m12); void setM13(final double m13); void setM20(final double m20); void setM21(final double m21); void setM22(final double m22); void setM23(final double m23); void setM30(final double m30); void setM31(final double m31); void setM32(final double m32); void setM33(final double m33); Matrix4 setIdentity(); @Override boolean isIdentity(); Matrix4 setValue(final int row, final int column, final double value); Matrix4 set(final double m00, final double m01, final double m02, final double m03, final double m10,
      final double m11, final double m12, final double m13, final double m20, final double m21, final double m22,
      final double m23, final double m30, final double m31, final double m32, final double m33); Matrix4 set(final ReadOnlyMatrix4 source); Matrix4 set(final ReadOnlyMatrix3 source); Matrix4 set(final ReadOnlyQuaternion quaternion); Matrix4 fromDoubleBuffer(final DoubleBuffer source); Matrix4 fromDoubleBuffer(final DoubleBuffer source, final boolean rowMajor); Matrix4 fromFloatBuffer(final FloatBuffer source); Matrix4 fromFloatBuffer(final FloatBuffer source, final boolean rowMajor); Matrix4 fromArray(final double[] source); Matrix4 fromArray(final double[] source, final boolean rowMajor); Matrix4 setColumn(final int columnIndex, final Vector4 columnData); Matrix4 setRow(final int rowIndex, final Vector4 rowData); Matrix4 fromAngleAxis(final double angle, final ReadOnlyVector3 axis); Matrix4 fromAngleNormalAxis(final double angle, final ReadOnlyVector3 axis); Matrix4 applyRotation(final double angle, final double x, final double y, final double z); Matrix4 applyRotationX(final double angle); Matrix4 applyRotationY(final double angle); Matrix4 applyRotationZ(final double angle); Matrix4 applyTranslationPost(final double x, final double y, final double z); Matrix4 applyTranslationPre(final double x, final double y, final double z); @Override Vector4 getColumn(final int index, final Vector4 store); @Override Vector4 getRow(final int index, final Vector4 store); @Override void toMatrix3(final Matrix3 store); @Override DoubleBuffer toDoubleBuffer(final DoubleBuffer store); @Override DoubleBuffer toDoubleBuffer(final DoubleBuffer store, final boolean rowMajor); @Override FloatBuffer toFloatBuffer(final FloatBuffer store); @Override FloatBuffer toFloatBuffer(final FloatBuffer store, final boolean rowMajor); @Override double[] toArray(final double[] store); @Override double[] toArray(final double[] store, final boolean rowMajor); @Override Matrix4 multiplyDiagonalPre(final ReadOnlyVector4 vec, final Matrix4 store); @Override Matrix4 multiplyDiagonalPost(final ReadOnlyVector4 vec, final Matrix4 store); Matrix4 multiplyLocal(final ReadOnlyMatrix4 matrix); @Override Matrix4 multiply(final ReadOnlyMatrix4 matrix, final Matrix4 store); Matrix4 multiplyLocal(final double scalar); @Override Matrix4 add(final ReadOnlyMatrix4 matrix, final Matrix4 store); Matrix4 addLocal(final ReadOnlyMatrix4 matrix); @Override Matrix4 subtract(final ReadOnlyMatrix4 matrix, final Matrix4 store); Matrix4 subtractLocal(final ReadOnlyMatrix4 matrix); @Override Matrix4 scale(final ReadOnlyVector4 scale, final Matrix4 store); Matrix4 scaleLocal(final ReadOnlyVector4 scale); @Override Matrix4 transpose(final Matrix4 store); Matrix4 transposeLocal(); @Override Matrix4 invert(final Matrix4 store); Matrix4 invertLocal(); @Override Matrix4 adjugate(final Matrix4 store); Matrix4 adjugateLocal(); @Override double determinant(); @Override Vector4 applyPre(final ReadOnlyVector4 vector, Vector4 store); @Override Vector4 applyPost(final ReadOnlyVector4 vector, Vector4 store); @Override Vector3 applyPostPoint(final ReadOnlyVector3 point, Vector3 store); @Override Vector3 applyPostVector(final ReadOnlyVector3 vector, Vector3 store); static boolean isValid(final ReadOnlyMatrix4 matrix); boolean isOrthonormal(); @Override String toString(); @Override int hashCode(); @Override boolean equals(final Object o); boolean strictEquals(final Object o); @Override Matrix4 clone(); @Override Class<? extends Matrix4> getClassTag(); @Override void write(final OutputCapsule capsule); @Override void read(final InputCapsule capsule); @Override void readExternal(final ObjectInput in); @Override void writeExternal(final ObjectOutput out); final static Matrix4 fetchTempInstance(); final static void releaseTempInstance(final Matrix4 mat); static final double ALLOWED_DEVIANCE; final static ReadOnlyMatrix4 IDENTITY; }
@Test public void testAngleAxis() { final Matrix4 mat4A = new Matrix4(); final double angle = MathUtils.HALF_PI; mat4A.fromAngleAxis(MathUtils.HALF_PI, Vector3.UNIT_X); assertEquals(new Matrix4( 1, 0, 0, 0, 0, Math.cos(angle), -Math.sin(angle), 0, 0, Math.sin(angle), Math.cos(angle), 0, 0, 0, 0, 1), mat4A); }