All Known Implementing Classes:
Float4

public interface ConstFloat4
Read-only access to a Float4. (native type: const Float4)
  • Method Summary

    Modifier and Type
    Method
    Description
    float
    get(int index)
    Return the specified component.
    void
    put(FloatBuffer storeBuffer)
    Write all 4 components to the specified buffer and advance the buffer's position by 4.
    float
    w()
    Return the 4th (W) component.
    float
    x()
    Return the first (X) component.
    float
    y()
    Return the 2nd (Y) component.
    float
    z()
    Return the 3rd (Z) component.
  • Method Details

    • get

      float get(int index)
      Return the specified component. The vector is unaffected.
      Parameters:
      index - 0, 1, 2, or 3
      Returns:
      the X component if index=0, the Y component if index=1, the Z component if index=2, or the W component if index=3
      Throws:
      IllegalArgumentException - if index is not 0, 1, 2, or 3
    • put

      void put(FloatBuffer storeBuffer)
      Write all 4 components to the specified buffer and advance the buffer's position by 4. The vector is unaffected.
      Parameters:
      storeBuffer - the destination buffer (not null)
    • w

      float w()
      Return the 4th (W) component. The vector is unaffected.
      Returns:
      the component value
    • x

      float x()
      Return the first (X) component. The vector is unaffected.
      Returns:
      the component value
    • y

      float y()
      Return the 2nd (Y) component. The vector is unaffected.
      Returns:
      the component value
    • z

      float z()
      Return the 3rd (Z) component. The vector is unaffected.
      Returns:
      the component value