Class VROverlayProjection

java.lang.Object
org.lwjgl.system.Pointer.Default
org.lwjgl.system.Struct<VROverlayProjection>
org.lwjgl.openvr.VROverlayProjection
All Implemented Interfaces:
AutoCloseable, org.lwjgl.system.NativeResource, org.lwjgl.system.Pointer

public class VROverlayProjection extends org.lwjgl.system.Struct<VROverlayProjection> implements org.lwjgl.system.NativeResource
Defines the project used in an overlay that is using SetOverlayTransformProjection.

Layout


 struct VROverlayProjection_t {
     float fLeft();
     float fRight();
     float fTop();
     float fBottom();
 }
  • Field Details

    • SIZEOF

      public static final int SIZEOF
      The struct size in bytes.
    • ALIGNOF

      public static final int ALIGNOF
      The struct alignment in bytes.
    • FLEFT

      public static final int FLEFT
      The struct member offsets.
    • FRIGHT

      public static final int FRIGHT
      The struct member offsets.
    • FTOP

      public static final int FTOP
      The struct member offsets.
    • FBOTTOM

      public static final int FBOTTOM
      The struct member offsets.
  • Constructor Details

    • VROverlayProjection

      public VROverlayProjection(ByteBuffer container)
      Creates a VROverlayProjection instance at the current position of the specified ByteBuffer container. Changes to the buffer's content will be visible to the struct instance and vice versa.

      The created instance holds a strong reference to the container object.

  • Method Details

    • sizeof

      public int sizeof()
      Specified by:
      sizeof in class org.lwjgl.system.Struct<VROverlayProjection>
    • fLeft

      public float fLeft()
      tangent of the left side of the frustum
    • fRight

      public float fRight()
      tangent of the right side of the frustum
    • fTop

      public float fTop()
      tangent of the top side of the frustum
    • fBottom

      public float fBottom()
      tangent of the bottom side of the frustum
    • fLeft

      public VROverlayProjection fLeft(float value)
      Sets the specified value to the fLeft() field.
    • fRight

      public VROverlayProjection fRight(float value)
      Sets the specified value to the fRight() field.
    • fTop

      public VROverlayProjection fTop(float value)
      Sets the specified value to the fTop() field.
    • fBottom

      public VROverlayProjection fBottom(float value)
      Sets the specified value to the fBottom() field.
    • set

      public VROverlayProjection set(float fLeft, float fRight, float fTop, float fBottom)
      Initializes this struct with the specified values.
    • set

      Copies the specified struct data to this struct.
      Parameters:
      src - the source struct
      Returns:
      this struct
    • malloc

      public static VROverlayProjection malloc()
      Returns a new VROverlayProjection instance allocated with memAlloc. The instance must be explicitly freed.
    • calloc

      public static VROverlayProjection calloc()
      Returns a new VROverlayProjection instance allocated with memCalloc. The instance must be explicitly freed.
    • create

      public static VROverlayProjection create()
      Returns a new VROverlayProjection instance allocated with BufferUtils.
    • create

      public static VROverlayProjection create(long address)
      Returns a new VROverlayProjection instance for the specified memory address.
    • createSafe

      public static @Nullable VROverlayProjection createSafe(long address)
      Like create, but returns null if address is NULL.
    • malloc

      public static VROverlayProjection.Buffer malloc(int capacity)
      Returns a new VROverlayProjection.Buffer instance allocated with memAlloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • calloc

      public static VROverlayProjection.Buffer calloc(int capacity)
      Returns a new VROverlayProjection.Buffer instance allocated with memCalloc. The instance must be explicitly freed.
      Parameters:
      capacity - the buffer capacity
    • create

      public static VROverlayProjection.Buffer create(int capacity)
      Returns a new VROverlayProjection.Buffer instance allocated with BufferUtils.
      Parameters:
      capacity - the buffer capacity
    • create

      public static VROverlayProjection.Buffer create(long address, int capacity)
      Create a VROverlayProjection.Buffer instance at the specified memory.
      Parameters:
      address - the memory address
      capacity - the buffer capacity
    • createSafe

      public static @Nullable VROverlayProjection.Buffer createSafe(long address, int capacity)
      Like create, but returns null if address is NULL.
    • malloc

      public static VROverlayProjection malloc(org.lwjgl.system.MemoryStack stack)
      Returns a new VROverlayProjection instance allocated on the specified MemoryStack.
      Parameters:
      stack - the stack from which to allocate
    • calloc

      public static VROverlayProjection calloc(org.lwjgl.system.MemoryStack stack)
      Returns a new VROverlayProjection instance allocated on the specified MemoryStack and initializes all its bits to zero.
      Parameters:
      stack - the stack from which to allocate
    • malloc

      public static VROverlayProjection.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
      Returns a new VROverlayProjection.Buffer instance allocated on the specified MemoryStack.
      Parameters:
      capacity - the buffer capacity
      stack - the stack from which to allocate
    • calloc

      public static VROverlayProjection.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
      Returns a new VROverlayProjection.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.
      Parameters:
      capacity - the buffer capacity
      stack - the stack from which to allocate
    • nfLeft

      public static float nfLeft(long struct)
      Unsafe version of fLeft().
    • nfRight

      public static float nfRight(long struct)
      Unsafe version of fRight().
    • nfTop

      public static float nfTop(long struct)
      Unsafe version of fTop().
    • nfBottom

      public static float nfBottom(long struct)
      Unsafe version of fBottom().
    • nfLeft

      public static void nfLeft(long struct, float value)
      Unsafe version of fLeft.
    • nfRight

      public static void nfRight(long struct, float value)
      Unsafe version of fRight.
    • nfTop

      public static void nfTop(long struct, float value)
      Unsafe version of fTop.
    • nfBottom

      public static void nfBottom(long struct, float value)
      Unsafe version of fBottom.