Package org.lwjgl.ovr

Class OVRDetectResult

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

public class OVRDetectResult extends org.lwjgl.system.Struct<OVRDetectResult> implements org.lwjgl.system.NativeResource
Return values for _Detect.

Layout


 struct ovrDetectResult {
     ovrBool IsOculusServiceRunning();
     ovrBool IsOculusHMDConnected();
     char[6];
 }
  • Field Details

    • SIZEOF

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

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

      public static final int ISOCULUSSERVICERUNNING
      The struct member offsets.
    • ISOCULUSHMDCONNECTED

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

    • OVRDetectResult

      public OVRDetectResult(ByteBuffer container)
      Creates a OVRDetectResult 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<OVRDetectResult>
    • IsOculusServiceRunning

      public boolean IsOculusServiceRunning()
      is False when the Oculus Service is not running. This means that the Oculus Service is either uninstalled or stopped. IsOculusHMDConnected will be False in this case.

      is True when the Oculus Service is running. This means that the Oculus Service is installed and running. IsOculusHMDConnected will reflect the state of the HMD.

    • IsOculusHMDConnected

      public boolean IsOculusHMDConnected()
      is False when an Oculus HMD is not detected. If the Oculus Service is not running, this will be False.

      is True when an Oculus HMD is detected. This implies that the Oculus Service is also installed and running.

    • malloc

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

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

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

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

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

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

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

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

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

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

      @Deprecated public static OVRDetectResult mallocStack()
      Deprecated.
      Deprecated for removal in 3.4.0. Use malloc(MemoryStack) instead.
    • callocStack

      @Deprecated public static OVRDetectResult callocStack()
      Deprecated.
      Deprecated for removal in 3.4.0. Use calloc(MemoryStack) instead.
    • mallocStack

      @Deprecated public static OVRDetectResult mallocStack(org.lwjgl.system.MemoryStack stack)
      Deprecated.
      Deprecated for removal in 3.4.0. Use malloc(MemoryStack) instead.
    • callocStack

      @Deprecated public static OVRDetectResult callocStack(org.lwjgl.system.MemoryStack stack)
      Deprecated.
      Deprecated for removal in 3.4.0. Use calloc(MemoryStack) instead.
    • mallocStack

      @Deprecated public static OVRDetectResult.Buffer mallocStack(int capacity)
      Deprecated.
      Deprecated for removal in 3.4.0. Use malloc(int, MemoryStack) instead.
    • callocStack

      @Deprecated public static OVRDetectResult.Buffer callocStack(int capacity)
      Deprecated.
      Deprecated for removal in 3.4.0. Use calloc(int, MemoryStack) instead.
    • mallocStack

      @Deprecated public static OVRDetectResult.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
      Deprecated.
      Deprecated for removal in 3.4.0. Use malloc(int, MemoryStack) instead.
    • callocStack

      @Deprecated public static OVRDetectResult.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
      Deprecated.
      Deprecated for removal in 3.4.0. Use calloc(int, MemoryStack) instead.
    • malloc

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

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

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

      public static OVRDetectResult.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
      Returns a new OVRDetectResult.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
    • nIsOculusServiceRunning

      public static boolean nIsOculusServiceRunning(long struct)
      Unsafe version of IsOculusServiceRunning().
    • nIsOculusHMDConnected

      public static boolean nIsOculusHMDConnected(long struct)
      Unsafe version of IsOculusHMDConnected().