Package org.lwjgl.ovr
Class OVRInitParams
java.lang.Object
org.lwjgl.system.Pointer.Default
org.lwjgl.system.Struct<OVRInitParams>
org.lwjgl.ovr.OVRInitParams
- All Implemented Interfaces:
AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class OVRInitParams
extends org.lwjgl.system.Struct<OVRInitParams>
implements org.lwjgl.system.NativeResource
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
org.lwjgl.system.Struct.StructValidationNested classes/interfaces inherited from interface org.lwjgl.system.Pointer
org.lwjgl.system.Pointer.Default -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe struct alignment in bytes.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct size in bytes.static final intThe struct member offsets.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE -
Constructor Summary
ConstructorsConstructorDescriptionOVRInitParams(ByteBuffer container) Creates aOVRInitParamsinstance at the current position of the specifiedByteBuffercontainer. -
Method Summary
Modifier and TypeMethodDescriptionstatic OVRInitParamscalloc()Returns a newOVRInitParamsinstance allocated withmemCalloc.static OVRInitParamscalloc(org.lwjgl.system.MemoryStack stack) Returns a newOVRInitParamsinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static OVRInitParamsDeprecated.static OVRInitParamscallocStack(org.lwjgl.system.MemoryStack stack) Deprecated.intrelative number of milliseconds to wait for a connection to the server before failing.ConnectionTimeoutMS(int value) Sets the specified value to theConnectionTimeoutMS()field.static OVRInitParamscreate()Returns a newOVRInitParamsinstance allocated withBufferUtils.static OVRInitParamscreate(long address) Returns a newOVRInitParamsinstance for the specified memory address.static @Nullable OVRInitParamscreateSafe(long address) intFlags()flags fromovrInitFlagsto override default behavior.Flags(int value) Sets the specified value to theFlags()field.@Nullable OVRLogCallbackuser-supplied log callback function, which may be called at any time asynchronously from multiple threads untilShutdowncompletes.LogCallback(@Nullable OVRLogCallbackI value) Sets the specified value to theLogCallback()field.static OVRInitParamsmalloc()Returns a newOVRInitParamsinstance allocated withmemAlloc.static OVRInitParamsmalloc(org.lwjgl.system.MemoryStack stack) Returns a newOVRInitParamsinstance allocated on the specifiedMemoryStack.static OVRInitParamsDeprecated.static OVRInitParamsmallocStack(org.lwjgl.system.MemoryStack stack) Deprecated.static intnConnectionTimeoutMS(long struct) Unsafe version ofConnectionTimeoutMS().static voidnConnectionTimeoutMS(long struct, int value) Unsafe version ofConnectionTimeoutMS.static intnFlags(long struct) Unsafe version ofFlags().static voidnFlags(long struct, int value) Unsafe version ofFlags.static @Nullable OVRLogCallbacknLogCallback(long struct) Unsafe version ofLogCallback().static voidnLogCallback(long struct, @Nullable OVRLogCallbackI value) Unsafe version ofLogCallback.static intnRequestedMinorVersion(long struct) Unsafe version ofRequestedMinorVersion().static voidnRequestedMinorVersion(long struct, int value) Unsafe version ofRequestedMinorVersion.static longnUserData(long struct) Unsafe version ofUserData().static voidnUserData(long struct, long value) Unsafe version ofUserData.intrequests 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.intsizeof()longUserData()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.Struct
clear, free, isNull, validate, validateMethods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toStringMethods 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 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 Details
-
sizeof
public int sizeof()- Specified by:
sizeofin classorg.lwjgl.system.Struct<OVRInitParams>
-
Flags
public int Flags()flags fromovrInitFlagsto override default behavior. Use 0 for the defaults. -
RequestedMinorVersion
public int RequestedMinorVersion()requests a specific minor version of the LibOVR runtime. Flags must includeInit_RequestVersionor this will be ignored andMINOR_VERSIONwill be used. If you are directly calling the LibOVRRT version ofInitializein 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 untilShutdowncompletes. UseNULLto 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 newOVRInitParamsinstance allocated withmemAlloc. The instance must be explicitly freed. -
calloc
Returns a newOVRInitParamsinstance allocated withmemCalloc. The instance must be explicitly freed. -
create
Returns a newOVRInitParamsinstance allocated withBufferUtils. -
create
Returns a newOVRInitParamsinstance 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 newOVRInitParamsinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
Returns a newOVRInitParamsinstance allocated on the specifiedMemoryStackand 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.
-