Package org.joml

Class Vector4f

java.lang.Object
org.joml.Vector4f
All Implemented Interfaces:
java.io.Externalizable, java.io.Serializable, Vector4fc

public class Vector4f
extends java.lang.Object
implements java.io.Externalizable, Vector4fc
See Also:
Serialized Form
  • Field Details

    • x

      public float x
    • y

      public float y
    • z

      public float z
    • w

      public float w
  • Constructor Details

    • Vector4f

      public Vector4f()
    • Vector4f

      public Vector4f​(Vector4fc vector4fc)
    • Vector4f

      public Vector4f​(Vector3fc vector3fc, float float1)
    • Vector4f

      public Vector4f​(Vector2fc vector2fc, float float1, float float2)
    • Vector4f

      public Vector4f​(float float1)
    • Vector4f

      public Vector4f​(float float1, float float2, float float3, float float4)
    • Vector4f

      public Vector4f​(java.nio.ByteBuffer byteBuffer)
    • Vector4f

      public Vector4f​(int int1, java.nio.ByteBuffer byteBuffer)
    • Vector4f

      public Vector4f​(java.nio.FloatBuffer floatBuffer)
    • Vector4f

      public Vector4f​(int int1, java.nio.FloatBuffer floatBuffer)
  • Method Details

    • x

      public float x()
      Specified by:
      x in interface Vector4fc
    • y

      public float y()
      Specified by:
      y in interface Vector4fc
    • z

      public float z()
      Specified by:
      z in interface Vector4fc
    • w

      public float w()
      Specified by:
      w in interface Vector4fc
    • set

      public Vector4f set​(Vector4fc vector4fc)
    • set

      public Vector4f set​(Vector4dc vector4dc)
    • set

      public Vector4f set​(Vector3fc vector3fc, float float1)
    • set

      public Vector4f set​(Vector2fc vector2fc, float float1, float float2)
    • set

      public Vector4f set​(float float1)
    • set

      public Vector4f set​(float float1, float float2, float float3, float float4)
    • set

      public Vector4f set​(java.nio.ByteBuffer byteBuffer)
    • set

      public Vector4f set​(int int1, java.nio.ByteBuffer byteBuffer)
    • set

      public Vector4f set​(java.nio.FloatBuffer floatBuffer)
    • set

      public Vector4f set​(int int1, java.nio.FloatBuffer floatBuffer)
    • setComponent

      public Vector4f setComponent​(int int1, float float1) throws java.lang.IllegalArgumentException
      Throws:
      java.lang.IllegalArgumentException
    • get

      public java.nio.FloatBuffer get​(java.nio.FloatBuffer floatBuffer)
      Specified by:
      get in interface Vector4fc
    • get

      public java.nio.FloatBuffer get​(int int1, java.nio.FloatBuffer floatBuffer)
      Specified by:
      get in interface Vector4fc
    • get

      public java.nio.ByteBuffer get​(java.nio.ByteBuffer byteBuffer)
      Specified by:
      get in interface Vector4fc
    • get

      public java.nio.ByteBuffer get​(int int1, java.nio.ByteBuffer byteBuffer)
      Specified by:
      get in interface Vector4fc
    • sub

      public Vector4f sub​(Vector4fc vector4fc)
    • sub

      public Vector4f sub​(float float1, float float2, float float3, float float4)
    • sub

      public Vector4f sub​(Vector4fc vector4fc, Vector4f vector4f)
      Specified by:
      sub in interface Vector4fc
    • sub

      public Vector4f sub​(float float1, float float2, float float3, float float4, Vector4f vector4f)
      Specified by:
      sub in interface Vector4fc
    • add

      public Vector4f add​(Vector4fc vector4fc)
    • add

      public Vector4f add​(Vector4fc vector4fc, Vector4f vector4f)
      Specified by:
      add in interface Vector4fc
    • add

      public Vector4f add​(float float1, float float2, float float3, float float4)
    • add

      public Vector4f add​(float float1, float float2, float float3, float float4, Vector4f vector4f)
      Specified by:
      add in interface Vector4fc
    • fma

      public Vector4f fma​(Vector4fc vector4fc, Vector4fc vector4fc2)
    • fma

      public Vector4f fma​(float float1, Vector4fc vector4fc)
    • fma

      public Vector4f fma​(Vector4fc vector4fc, Vector4fc vector4fc2, Vector4f vector4f)
      Specified by:
      fma in interface Vector4fc
    • fma

      public Vector4f fma​(float float1, Vector4fc vector4fc, Vector4f vector4f)
      Specified by:
      fma in interface Vector4fc
    • mul

      public Vector4f mul​(Vector4fc vector4fc)
    • mul

      public Vector4f mul​(Vector4fc vector4fc, Vector4f vector4f)
      Specified by:
      mul in interface Vector4fc
    • div

      public Vector4f div​(Vector4fc vector4fc)
    • div

      public Vector4f div​(Vector4fc vector4fc, Vector4f vector4f)
      Specified by:
      div in interface Vector4fc
    • mul

      public Vector4f mul​(Matrix4fc matrix4fc)
    • mul

      public Vector4f mul​(Matrix4fc matrix4fc, Vector4f vector4f)
      Specified by:
      mul in interface Vector4fc
    • mul

      public Vector4f mul​(Matrix4x3fc matrix4x3fc)
    • mul

      public Vector4f mul​(Matrix4x3fc matrix4x3fc, Vector4f vector4f)
      Specified by:
      mul in interface Vector4fc
    • mulProject

      public Vector4f mulProject​(Matrix4fc matrix4fc, Vector4f vector4f)
      Specified by:
      mulProject in interface Vector4fc
    • mulProject

      public Vector4f mulProject​(Matrix4fc matrix4fc)
    • mul

      public Vector4f mul​(float float1)
    • mul

      public Vector4f mul​(float float1, Vector4f vector4f)
      Specified by:
      mul in interface Vector4fc
    • mul

      public Vector4f mul​(float float1, float float2, float float3, float float4)
    • mul

      public Vector4f mul​(float float1, float float2, float float3, float float4, Vector4f vector4f)
      Specified by:
      mul in interface Vector4fc
    • div

      public Vector4f div​(float float1)
    • div

      public Vector4f div​(float float1, Vector4f vector4f)
      Specified by:
      div in interface Vector4fc
    • div

      public Vector4f div​(float float1, float float2, float float3, float float4)
    • div

      public Vector4f div​(float float1, float float2, float float3, float float4, Vector4f vector4f)
      Specified by:
      div in interface Vector4fc
    • rotate

      public Vector4f rotate​(Quaternionfc quaternionfc)
    • rotate

      public Vector4f rotate​(Quaternionfc quaternionfc, Vector4f vector4f)
      Specified by:
      rotate in interface Vector4fc
    • lengthSquared

      public float lengthSquared()
      Specified by:
      lengthSquared in interface Vector4fc
    • length

      public float length()
      Specified by:
      length in interface Vector4fc
    • normalize

      public Vector4f normalize()
    • normalize

      public Vector4f normalize​(Vector4f vector4f)
      Specified by:
      normalize in interface Vector4fc
    • normalize3

      public Vector4f normalize3()
    • distance

      public float distance​(Vector4fc vector4fc)
      Specified by:
      distance in interface Vector4fc
    • distance

      public float distance​(float float1, float float2, float float3, float float4)
      Specified by:
      distance in interface Vector4fc
    • dot

      public float dot​(Vector4fc vector4fc)
      Specified by:
      dot in interface Vector4fc
    • dot

      public float dot​(float float1, float float2, float float3, float float4)
      Specified by:
      dot in interface Vector4fc
    • angleCos

      public float angleCos​(Vector4fc vector4fc)
      Specified by:
      angleCos in interface Vector4fc
    • angle

      public float angle​(Vector4fc vector4fc)
      Specified by:
      angle in interface Vector4fc
    • zero

      public Vector4f zero()
    • negate

      public Vector4f negate()
    • negate

      public Vector4f negate​(Vector4f vector4f)
      Specified by:
      negate in interface Vector4fc
    • toString

      public java.lang.String toString()
      Overrides:
      toString in class java.lang.Object
    • toString

      public java.lang.String toString​(java.text.NumberFormat numberFormat)
    • writeExternal

      public void writeExternal​(java.io.ObjectOutput objectOutput) throws java.io.IOException
      Specified by:
      writeExternal in interface java.io.Externalizable
      Throws:
      java.io.IOException
    • readExternal

      public void readExternal​(java.io.ObjectInput objectInput) throws java.io.IOException, java.lang.ClassNotFoundException
      Specified by:
      readExternal in interface java.io.Externalizable
      Throws:
      java.io.IOException
      java.lang.ClassNotFoundException
    • min

      public Vector4f min​(Vector4fc vector4fc)
    • max

      public Vector4f max​(Vector4fc vector4fc)
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class java.lang.Object
    • equals

      public boolean equals​(java.lang.Object object)
      Overrides:
      equals in class java.lang.Object
    • smoothStep

      public Vector4f smoothStep​(Vector4fc vector4fc, float float1, Vector4f vector4f)
      Specified by:
      smoothStep in interface Vector4fc
    • hermite

      public Vector4f hermite​(Vector4fc vector4fc, Vector4fc vector4fc2, Vector4fc vector4fc3, float float1, Vector4f vector4f)
      Specified by:
      hermite in interface Vector4fc
    • lerp

      public Vector4f lerp​(Vector4fc vector4fc, float float1)
    • lerp

      public Vector4f lerp​(Vector4fc vector4fc, float float1, Vector4f vector4f)
      Specified by:
      lerp in interface Vector4fc
    • toImmutable

      public Vector4fc toImmutable()