Package org.lwjgl.ovr
Class OVRInitParams
- All Implemented Interfaces:
AutoCloseable
,NativeResource
,Pointer
Parameters for
Initialize
.
Layout
struct ovrInitParams {
uint32_t Flags()
;
uint32_t RequestedMinorVersion()
;
ovrLogCallback
LogCallback()
;
uintptr_t UserData()
;
uint32_t ConnectionTimeoutMS()
;
}
-
Nested Class Summary
Nested classes/interfaces inherited from class org.lwjgl.system.Struct
Struct.StructValidation
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
Field Summary
Modifier and TypeFieldDescriptionstatic final int
The struct alignment in bytes.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct member offsets.static final int
The struct size in bytes.static final int
The struct member offsets.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE
-
Constructor Summary
ConstructorDescriptionOVRInitParams
(ByteBuffer container) Creates aOVRInitParams
instance at the current position of the specifiedByteBuffer
container. -
Method Summary
Modifier and TypeMethodDescriptionstatic OVRInitParams
calloc()
Returns a newOVRInitParams
instance allocated withmemCalloc
.static OVRInitParams
calloc
(MemoryStack stack) Returns a newOVRInitParams
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static OVRInitParams
Deprecated.static OVRInitParams
callocStack
(MemoryStack stack) Deprecated.int
relative number of milliseconds to wait for a connection to the server before failing.ConnectionTimeoutMS
(int value) Sets the specified value to theConnectionTimeoutMS()
field.static OVRInitParams
create()
Returns a newOVRInitParams
instance allocated withBufferUtils
.static OVRInitParams
create
(long address) Returns a newOVRInitParams
instance for the specified memory address.static OVRInitParams
createSafe
(long address) int
Flags()
flags fromovrInitFlags
to override default behavior.Flags
(int value) Sets the specified value to theFlags()
field.user-supplied log callback function, which may be called at any time asynchronously from multiple threads untilShutdown
completes.LogCallback
(OVRLogCallbackI value) Sets the specified value to theLogCallback()
field.static OVRInitParams
malloc()
Returns a newOVRInitParams
instance allocated withmemAlloc
.static OVRInitParams
malloc
(MemoryStack stack) Returns a newOVRInitParams
instance allocated on the specifiedMemoryStack
.static OVRInitParams
Deprecated.static OVRInitParams
mallocStack
(MemoryStack stack) Deprecated.static int
nConnectionTimeoutMS
(long struct) Unsafe version ofConnectionTimeoutMS()
.static void
nConnectionTimeoutMS
(long struct, int value) Unsafe version ofConnectionTimeoutMS
.static int
nFlags
(long struct) Unsafe version ofFlags()
.static void
nFlags
(long struct, int value) Unsafe version ofFlags
.static OVRLogCallback
nLogCallback
(long struct) Unsafe version ofLogCallback()
.static void
nLogCallback
(long struct, OVRLogCallbackI value) Unsafe version ofLogCallback
.static int
nRequestedMinorVersion
(long struct) Unsafe version ofRequestedMinorVersion()
.static void
nRequestedMinorVersion
(long struct, int value) Unsafe version ofRequestedMinorVersion
.static long
nUserData
(long struct) Unsafe version ofUserData()
.static void
nUserData
(long struct, long value) Unsafe version ofUserData
.int
requests a specific minor version of the LibOVR runtime.RequestedMinorVersion
(int value) Sets the specified value to theRequestedMinorVersion()
field.set
(int Flags, int RequestedMinorVersion, OVRLogCallbackI LogCallback, long UserData, int ConnectionTimeoutMS) Initializes this struct with the specified values.set
(OVRInitParams src) Copies the specified struct data to this struct.int
sizeof()
Returnssizeof(struct)
.long
UserData()
user-supplied data which is passed as-is toLogCallback
.UserData
(long value) Sets the specified value to theUserData()
field.Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toString
Methods inherited from interface org.lwjgl.system.NativeResource
close, free
-
Field Details
-
SIZEOF
public static final int SIZEOFThe struct size in bytes. -
ALIGNOF
public static final int ALIGNOFThe struct alignment in bytes. -
FLAGS
public static final int FLAGSThe struct member offsets. -
REQUESTEDMINORVERSION
public static final int REQUESTEDMINORVERSIONThe struct member offsets. -
LOGCALLBACK
public static final int LOGCALLBACKThe struct member offsets. -
USERDATA
public static final int USERDATAThe struct member offsets. -
CONNECTIONTIMEOUTMS
public static final int CONNECTIONTIMEOUTMSThe struct member offsets.
-
-
Constructor Details
-
OVRInitParams
Creates aOVRInitParams
instance at the current position of the specifiedByteBuffer
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()Description copied from class:Struct
Returnssizeof(struct)
.- Specified by:
sizeof
in classStruct<OVRInitParams>
-
Flags
public int Flags()flags fromovrInitFlags
to override default behavior. Use 0 for the defaults. -
RequestedMinorVersion
public int RequestedMinorVersion()requests a specific minor version of the LibOVR runtime. Flags must includeInit_RequestVersion
or this will be ignored andMINOR_VERSION
will be used. If you are directly calling the LibOVRRT version ofInitialize
in the LibOVRRT DLL then this must be valid and includeInit_RequestVersion
. -
LogCallback
user-supplied log callback function, which may be called at any time asynchronously from multiple threads untilShutdown
completes. UseNULL
to specify no log callback. -
UserData
public long 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
public int ConnectionTimeoutMS()relative number of milliseconds to wait for a connection to the server before failing. Use 0 for the default timeout. -
Flags
Sets the specified value to theFlags()
field. -
RequestedMinorVersion
Sets the specified value to theRequestedMinorVersion()
field. -
LogCallback
Sets the specified value to theLogCallback()
field. -
UserData
Sets the specified value to theUserData()
field. -
ConnectionTimeoutMS
Sets the specified value to theConnectionTimeoutMS()
field. -
set
public OVRInitParams set(int Flags, int RequestedMinorVersion, OVRLogCallbackI LogCallback, long UserData, int ConnectionTimeoutMS) 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
Returns a newOVRInitParams
instance allocated withmemAlloc
. The instance must be explicitly freed. -
calloc
Returns a newOVRInitParams
instance allocated withmemCalloc
. The instance must be explicitly freed. -
create
Returns a newOVRInitParams
instance allocated withBufferUtils
. -
create
Returns a newOVRInitParams
instance for the specified memory address. -
createSafe
-
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)
instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(MemoryStack)
instead. -
malloc
Returns a newOVRInitParams
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
calloc
Returns a newOVRInitParams
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
nFlags
public static int nFlags(long struct) Unsafe version ofFlags()
. -
nRequestedMinorVersion
public static int nRequestedMinorVersion(long struct) Unsafe version ofRequestedMinorVersion()
. -
nLogCallback
Unsafe version ofLogCallback()
. -
nUserData
public static long nUserData(long struct) Unsafe version ofUserData()
. -
nConnectionTimeoutMS
public static int nConnectionTimeoutMS(long struct) Unsafe version ofConnectionTimeoutMS()
. -
nFlags
public static void nFlags(long struct, int value) Unsafe version ofFlags
. -
nRequestedMinorVersion
public static void nRequestedMinorVersion(long struct, int value) Unsafe version ofRequestedMinorVersion
. -
nLogCallback
Unsafe version ofLogCallback
. -
nUserData
public static void nUserData(long struct, long value) Unsafe version ofUserData
. -
nConnectionTimeoutMS
public static void nConnectionTimeoutMS(long struct, int value) Unsafe version ofConnectionTimeoutMS
.
-