Package org.lwjgl.ovr
Class OVRTouchHapticsDesc
- All Implemented Interfaces:
AutoCloseable
,NativeResource
,Pointer
Describes the Touch Haptics engine.
Layout
struct ovrTouchHapticsDesc {
int SampleRateHz()
;
int SampleSizeInBytes()
;
int QueueMinSizeToAvoidStarvation()
;
int SubmitMinSamples()
;
int SubmitMaxSamples()
;
int SubmitOptimalSamples()
;
}
-
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 size in bytes.static final int
The struct member offsets.static final int
The struct member offsets.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
ConstructorDescriptionOVRTouchHapticsDesc
(ByteBuffer container) Creates aOVRTouchHapticsDesc
instance at the current position of the specifiedByteBuffer
container. -
Method Summary
Modifier and TypeMethodDescriptionstatic OVRTouchHapticsDesc
calloc()
Returns a newOVRTouchHapticsDesc
instance allocated withmemCalloc
.static OVRTouchHapticsDesc.Buffer
calloc
(int capacity) Returns a newOVRTouchHapticsDesc.Buffer
instance allocated withmemCalloc
.static OVRTouchHapticsDesc.Buffer
calloc
(int capacity, MemoryStack stack) Returns a newOVRTouchHapticsDesc.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static OVRTouchHapticsDesc
calloc
(MemoryStack stack) Returns a newOVRTouchHapticsDesc
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static OVRTouchHapticsDesc
Deprecated.static OVRTouchHapticsDesc.Buffer
callocStack
(int capacity) Deprecated.static OVRTouchHapticsDesc.Buffer
callocStack
(int capacity, MemoryStack stack) Deprecated.static OVRTouchHapticsDesc
callocStack
(MemoryStack stack) Deprecated.static OVRTouchHapticsDesc
create()
Returns a newOVRTouchHapticsDesc
instance allocated withBufferUtils
.static OVRTouchHapticsDesc.Buffer
create
(int capacity) Returns a newOVRTouchHapticsDesc.Buffer
instance allocated withBufferUtils
.static OVRTouchHapticsDesc
create
(long address) Returns a newOVRTouchHapticsDesc
instance for the specified memory address.static OVRTouchHapticsDesc.Buffer
create
(long address, int capacity) Create aOVRTouchHapticsDesc.Buffer
instance at the specified memory.static OVRTouchHapticsDesc
createSafe
(long address) static OVRTouchHapticsDesc.Buffer
createSafe
(long address, int capacity) static OVRTouchHapticsDesc
malloc()
Returns a newOVRTouchHapticsDesc
instance allocated withmemAlloc
.static OVRTouchHapticsDesc.Buffer
malloc
(int capacity) Returns a newOVRTouchHapticsDesc.Buffer
instance allocated withmemAlloc
.static OVRTouchHapticsDesc.Buffer
malloc
(int capacity, MemoryStack stack) Returns a newOVRTouchHapticsDesc.Buffer
instance allocated on the specifiedMemoryStack
.static OVRTouchHapticsDesc
malloc
(MemoryStack stack) Returns a newOVRTouchHapticsDesc
instance allocated on the specifiedMemoryStack
.static OVRTouchHapticsDesc
Deprecated.static OVRTouchHapticsDesc.Buffer
mallocStack
(int capacity) Deprecated.static OVRTouchHapticsDesc.Buffer
mallocStack
(int capacity, MemoryStack stack) Deprecated.static OVRTouchHapticsDesc
mallocStack
(MemoryStack stack) Deprecated.static int
nQueueMinSizeToAvoidStarvation
(long struct) Unsafe version ofQueueMinSizeToAvoidStarvation()
.static int
nSampleRateHz
(long struct) Unsafe version ofSampleRateHz()
.static int
nSampleSizeInBytes
(long struct) Unsafe version ofSampleSizeInBytes()
.static int
nSubmitMaxSamples
(long struct) Unsafe version ofSubmitMaxSamples()
.static int
nSubmitMinSamples
(long struct) Unsafe version ofSubmitMinSamples()
.static int
nSubmitOptimalSamples
(long struct) Unsafe version ofSubmitOptimalSamples()
.int
Queue size that would guarantee Haptics engine would not starve for data.int
Haptics engine frequency/sample-rate, sample time in seconds equals1.0/sampleRateHz
int
Size of each Haptics sample, sample value range is[0, 2^(Bytes*8)-1]
int
sizeof()
Returnssizeof(struct)
.int
Maximum number of samples that can be sent to Haptics throughSubmitControllerVibration
int
Minimum number of samples that can be sent to Haptics throughSubmitControllerVibration
int
Optimal number of samples that can be sent to Haptics throughSubmitControllerVibration
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. -
SAMPLERATEHZ
public static final int SAMPLERATEHZThe struct member offsets. -
SAMPLESIZEINBYTES
public static final int SAMPLESIZEINBYTESThe struct member offsets. -
QUEUEMINSIZETOAVOIDSTARVATION
public static final int QUEUEMINSIZETOAVOIDSTARVATIONThe struct member offsets. -
SUBMITMINSAMPLES
public static final int SUBMITMINSAMPLESThe struct member offsets. -
SUBMITMAXSAMPLES
public static final int SUBMITMAXSAMPLESThe struct member offsets. -
SUBMITOPTIMALSAMPLES
public static final int SUBMITOPTIMALSAMPLESThe struct member offsets.
-
-
Constructor Details
-
OVRTouchHapticsDesc
Creates aOVRTouchHapticsDesc
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<OVRTouchHapticsDesc>
-
SampleRateHz
public int SampleRateHz()Haptics engine frequency/sample-rate, sample time in seconds equals1.0/sampleRateHz
-
SampleSizeInBytes
public int SampleSizeInBytes()Size of each Haptics sample, sample value range is[0, 2^(Bytes*8)-1]
-
QueueMinSizeToAvoidStarvation
public int QueueMinSizeToAvoidStarvation()Queue size that would guarantee Haptics engine would not starve for data. Make sure size doesn't drop below it for best results. -
SubmitMinSamples
public int SubmitMinSamples()Minimum number of samples that can be sent to Haptics throughSubmitControllerVibration
-
SubmitMaxSamples
public int SubmitMaxSamples()Maximum number of samples that can be sent to Haptics throughSubmitControllerVibration
-
SubmitOptimalSamples
public int SubmitOptimalSamples()Optimal number of samples that can be sent to Haptics throughSubmitControllerVibration
-
malloc
Returns a newOVRTouchHapticsDesc
instance allocated withmemAlloc
. The instance must be explicitly freed. -
calloc
Returns a newOVRTouchHapticsDesc
instance allocated withmemCalloc
. The instance must be explicitly freed. -
create
Returns a newOVRTouchHapticsDesc
instance allocated withBufferUtils
. -
create
Returns a newOVRTouchHapticsDesc
instance for the specified memory address. -
createSafe
-
malloc
Returns a newOVRTouchHapticsDesc.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
Returns a newOVRTouchHapticsDesc.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
Returns a newOVRTouchHapticsDesc.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
Create aOVRTouchHapticsDesc.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
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. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)
instead. -
mallocStack
Deprecated.Deprecated for removal in 3.4.0. Usemalloc(int, MemoryStack)
instead. -
callocStack
Deprecated.Deprecated for removal in 3.4.0. Usecalloc(int, MemoryStack)
instead. -
malloc
Returns a newOVRTouchHapticsDesc
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
calloc
Returns a newOVRTouchHapticsDesc
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
malloc
Returns a newOVRTouchHapticsDesc.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
calloc
Returns a newOVRTouchHapticsDesc.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacitystack
- the stack from which to allocate
-
nSampleRateHz
public static int nSampleRateHz(long struct) Unsafe version ofSampleRateHz()
. -
nSampleSizeInBytes
public static int nSampleSizeInBytes(long struct) Unsafe version ofSampleSizeInBytes()
. -
nQueueMinSizeToAvoidStarvation
public static int nQueueMinSizeToAvoidStarvation(long struct) Unsafe version ofQueueMinSizeToAvoidStarvation()
. -
nSubmitMinSamples
public static int nSubmitMinSamples(long struct) Unsafe version ofSubmitMinSamples()
. -
nSubmitMaxSamples
public static int nSubmitMaxSamples(long struct) Unsafe version ofSubmitMaxSamples()
. -
nSubmitOptimalSamples
public static int nSubmitOptimalSamples(long struct) Unsafe version ofSubmitOptimalSamples()
.
-