Package org.lwjgl.ovr
Class OVRInitParams
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.ovr.OVRInitParams
-
- All Implemented Interfaces:
- java.lang.AutoCloseable, NativeResource, Pointer
public class OVRInitParams extends Struct
Parameters forOVR.ovr_Initialize(org.lwjgl.ovr.OVRInitParams).Member documentation
Flags– flags fromovrInitFlagsto override default behavior. Use 0 for the defaults.RequestedMinorVersion– requests a specific minimum minor version of the LibOVR runtime. Flags must includeOVR.ovrInit_RequestVersionor this will be ignored andOVRVersion.OVR_MINOR_VERSIONwill be used.LogCallback– user-supplied log callback function, which may be called at any time asynchronously from multiple threads untilOVR.ovr_Shutdown()completes. UseNULLto specify no log callback.UserData– user-supplied data which is passed as-is toLogCallback. Typically this is used to store an application-specific pointer which is read in the callback function.ConnectionTimeoutMS– relative number of milliseconds to wait for a connection to the server before failing. Use 0 for the default timeout.
Layout
struct ovrInitParams { uint32_t Flags; uint32_t RequestedMinorVersion; ovrLogCallback LogCallback; uintptr_t UserData; uint32_t ConnectionTimeoutMS; char[4]; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class and Description static classOVRInitParams.BufferAn array ofOVRInitParamsstructs.-
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
-
Field Summary
Fields Modifier and Type Field and Description static intSIZEOFThe struct size in bytes.-
Fields inherited from interface org.lwjgl.system.Pointer
POINTER_SHIFT, POINTER_SIZE
-
-
Constructor Summary
Constructors Constructor and Description OVRInitParams(java.nio.ByteBuffer container)Creates aOVRInitParamsinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method and Description static OVRInitParamscalloc()Returns a newOVRInitParamsinstance allocated withmemCalloc.static OVRInitParams.Buffercalloc(int capacity)Returns a newOVRInitParams.Bufferinstance allocated withmemCalloc.static OVRInitParamscallocStack()Returns a newOVRInitParamsinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static OVRInitParams.BuffercallocStack(int capacity)Returns a newOVRInitParams.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static OVRInitParams.BuffercallocStack(int capacity, MemoryStack stack)Returns a newOVRInitParams.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static OVRInitParamscallocStack(MemoryStack stack)Returns a newOVRInitParamsinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.intConnectionTimeoutMS()Returns the value of theConnectionTimeoutMSfield.OVRInitParamsConnectionTimeoutMS(int value)Sets the specified value to theConnectionTimeoutMSfield.static OVRInitParamscreate()Returns a newOVRInitParamsinstance allocated withBufferUtils.static OVRInitParams.Buffercreate(int capacity)Returns a newOVRInitParams.Bufferinstance allocated withBufferUtils.static OVRInitParamscreate(long address)Returns a newOVRInitParamsinstance for the specified memory address ornullif the address isNULL.static OVRInitParams.Buffercreate(long address, int capacity)Create aOVRInitParams.Bufferinstance at the specified memory.intFlags()Returns the value of theFlagsfield.OVRInitParamsFlags(int value)Sets the specified value to theFlagsfield.OVRLogCallbackLogCallback()Returns theOVRLogCallbackinstance at theLogCallbackfield.OVRInitParamsLogCallback(OVRLogCallbackI value)Sets the address of the specifiedOVRLogCallbackIto theLogCallbackfield.static OVRInitParamsmalloc()Returns a newOVRInitParamsinstance allocated withmemAlloc.static OVRInitParams.Buffermalloc(int capacity)Returns a newOVRInitParams.Bufferinstance allocated withmemAlloc.static OVRInitParamsmallocStack()Returns a newOVRInitParamsinstance allocated on the thread-localMemoryStack.static OVRInitParams.BuffermallocStack(int capacity)Returns a newOVRInitParams.Bufferinstance allocated on the thread-localMemoryStack.static OVRInitParams.BuffermallocStack(int capacity, MemoryStack stack)Returns a newOVRInitParams.Bufferinstance allocated on the specifiedMemoryStack.static OVRInitParamsmallocStack(MemoryStack stack)Returns a newOVRInitParamsinstance allocated on the specifiedMemoryStack.OVRInitParamsnset(long struct)Unsafe version ofset.intRequestedMinorVersion()Returns the value of theRequestedMinorVersionfield.OVRInitParamsRequestedMinorVersion(int value)Sets the specified value to theRequestedMinorVersionfield.OVRInitParamsset(int Flags, int RequestedMinorVersion, OVRLogCallbackI LogCallback, long UserData, int ConnectionTimeoutMS)Initializes this struct with the specified values.OVRInitParamsset(OVRInitParams src)Copies the specified struct data to this struct.intsizeof()Returns thesizeof(struct).longUserData()Returns the value of theUserDatafield.OVRInitParamsUserData(long value)Sets the specified value to theUserDatafield.-
Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
-
Methods inherited from interface org.lwjgl.system.NativeResource
close
-
-
-
-
Constructor Detail
-
OVRInitParams
public OVRInitParams(java.nio.ByteBuffer container)
Creates aOVRInitParamsinstance at the current position of the specifiedByteBuffercontainer. 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 Detail
-
sizeof
public int sizeof()
Description copied from class:StructReturns thesizeof(struct).
-
Flags
public int Flags()
Returns the value of theFlagsfield.
-
RequestedMinorVersion
public int RequestedMinorVersion()
Returns the value of theRequestedMinorVersionfield.
-
LogCallback
public OVRLogCallback LogCallback()
Returns theOVRLogCallbackinstance at theLogCallbackfield.
-
UserData
public long UserData()
Returns the value of theUserDatafield.
-
ConnectionTimeoutMS
public int ConnectionTimeoutMS()
Returns the value of theConnectionTimeoutMSfield.
-
Flags
public OVRInitParams Flags(int value)
Sets the specified value to theFlagsfield.
-
RequestedMinorVersion
public OVRInitParams RequestedMinorVersion(int value)
Sets the specified value to theRequestedMinorVersionfield.
-
LogCallback
public OVRInitParams LogCallback(OVRLogCallbackI value)
Sets the address of the specifiedOVRLogCallbackIto theLogCallbackfield.
-
UserData
public OVRInitParams UserData(long value)
Sets the specified value to theUserDatafield.
-
ConnectionTimeoutMS
public OVRInitParams ConnectionTimeoutMS(int value)
Sets the specified value to theConnectionTimeoutMSfield.
-
set
public OVRInitParams set(int Flags, int RequestedMinorVersion, OVRLogCallbackI LogCallback, long UserData, int ConnectionTimeoutMS)
Initializes this struct with the specified values.
-
nset
public OVRInitParams nset(long struct)
Unsafe version ofset.
-
set
public OVRInitParams set(OVRInitParams src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static OVRInitParams malloc()
Returns a newOVRInitParamsinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static OVRInitParams calloc()
Returns a newOVRInitParamsinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static OVRInitParams create()
Returns a newOVRInitParamsinstance allocated withBufferUtils.
-
create
public static OVRInitParams create(long address)
Returns a newOVRInitParamsinstance for the specified memory address ornullif the address isNULL.
-
malloc
public static OVRInitParams.Buffer malloc(int capacity)
Returns a newOVRInitParams.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static OVRInitParams.Buffer calloc(int capacity)
Returns a newOVRInitParams.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static OVRInitParams.Buffer create(int capacity)
Returns a newOVRInitParams.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static OVRInitParams.Buffer create(long address, int capacity)
Create aOVRInitParams.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
mallocStack
public static OVRInitParams mallocStack()
Returns a newOVRInitParamsinstance allocated on the thread-localMemoryStack.
-
callocStack
public static OVRInitParams callocStack()
Returns a newOVRInitParamsinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.
-
mallocStack
public static OVRInitParams mallocStack(MemoryStack stack)
Returns a newOVRInitParamsinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
callocStack
public static OVRInitParams callocStack(MemoryStack stack)
Returns a newOVRInitParamsinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
mallocStack
public static OVRInitParams.Buffer mallocStack(int capacity)
Returns a newOVRInitParams.Bufferinstance allocated on the thread-localMemoryStack.- Parameters:
capacity- the buffer capacity
-
callocStack
public static OVRInitParams.Buffer callocStack(int capacity)
Returns a newOVRInitParams.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacity
-
mallocStack
public static OVRInitParams.Buffer mallocStack(int capacity, MemoryStack stack)
Returns a newOVRInitParams.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
callocStack
public static OVRInitParams.Buffer callocStack(int capacity, MemoryStack stack)
Returns a newOVRInitParams.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
-