Package org.lwjgl.openxr
Class XrHapticBaseHeader
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.openxr.XrHapticBaseHeader
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class XrHapticBaseHeader extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceBase header for haptic feedback.Valid Usage (Implicit)
typemust beTYPE_HAPTIC_VIBRATIONnextmust beNULLor a valid pointer to the next structure in a structure chain
See Also
XrHapticVibration,XrInteractionProfileAnalogThresholdVALVE,ApplyHapticFeedbackLayout
struct XrHapticBaseHeader { XrStructureTypetype(); void const *next(); }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classXrHapticBaseHeader.BufferAn array ofXrHapticBaseHeaderstructs.
-
Constructor Summary
Constructors Constructor Description XrHapticBaseHeader(java.nio.ByteBuffer container)Creates aXrHapticBaseHeaderinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static XrHapticBaseHeadercalloc()Returns a newXrHapticBaseHeaderinstance allocated withmemCalloc.static XrHapticBaseHeader.Buffercalloc(int capacity)Returns a newXrHapticBaseHeader.Bufferinstance allocated withmemCalloc.static XrHapticBaseHeader.Buffercalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newXrHapticBaseHeader.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static XrHapticBaseHeadercalloc(org.lwjgl.system.MemoryStack stack)Returns a newXrHapticBaseHeaderinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static XrHapticBaseHeadercreate()Returns a newXrHapticBaseHeaderinstance allocated withBufferUtils.static XrHapticBaseHeader.Buffercreate(int capacity)Returns a newXrHapticBaseHeader.Bufferinstance allocated withBufferUtils.static XrHapticBaseHeadercreate(long address)Returns a newXrHapticBaseHeaderinstance for the specified memory address.static XrHapticBaseHeader.Buffercreate(long address, int capacity)Create aXrHapticBaseHeader.Bufferinstance at the specified memory.static XrHapticBaseHeadercreate(XrHapticVibration value)Upcasts the specifiedXrHapticVibrationinstance toXrHapticBaseHeader.static XrHapticBaseHeader.Buffercreate(XrHapticVibration.Buffer value)Upcasts the specifiedXrHapticVibration.Bufferinstance toXrHapticBaseHeader.Buffer.static XrHapticBaseHeadercreateSafe(long address)static XrHapticBaseHeader.BuffercreateSafe(long address, int capacity)static XrHapticBaseHeadermalloc()Returns a newXrHapticBaseHeaderinstance allocated withmemAlloc.static XrHapticBaseHeader.Buffermalloc(int capacity)Returns a newXrHapticBaseHeader.Bufferinstance allocated withmemAlloc.static XrHapticBaseHeader.Buffermalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newXrHapticBaseHeader.Bufferinstance allocated on the specifiedMemoryStack.static XrHapticBaseHeadermalloc(org.lwjgl.system.MemoryStack stack)Returns a newXrHapticBaseHeaderinstance allocated on the specifiedMemoryStack.longnext()NULLor a pointer to the next structure in a structure chain.XrHapticBaseHeadernext(long value)Sets the specified value to thenext()field.static longnnext(long struct)Unsafe version ofnext().static voidnnext(long struct, long value)Unsafe version ofnext.static intntype(long struct)Unsafe version oftype().static voidntype(long struct, int value)Unsafe version oftype.XrHapticBaseHeaderset(int type, long next)Initializes this struct with the specified values.XrHapticBaseHeaderset(XrHapticBaseHeader src)Copies the specified struct data to this struct.intsizeof()inttype()theXrStructureTypeof this structure.XrHapticBaseHeadertype(int value)Sets the specified value to thetype()field.
-
-
-
Constructor Detail
-
XrHapticBaseHeader
public XrHapticBaseHeader(java.nio.ByteBuffer container)
Creates aXrHapticBaseHeaderinstance 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()
- Specified by:
sizeofin classorg.lwjgl.system.Struct
-
type
public int type()
theXrStructureTypeof this structure. This base structure itself has no associatedXrStructureTypevalue.
-
next
public long next()
NULLor a pointer to the next structure in a structure chain. No such structures are defined in core OpenXR.
-
type
public XrHapticBaseHeader type(int value)
Sets the specified value to thetype()field.
-
next
public XrHapticBaseHeader next(long value)
Sets the specified value to thenext()field.
-
set
public XrHapticBaseHeader set(int type, long next)
Initializes this struct with the specified values.
-
set
public XrHapticBaseHeader set(XrHapticBaseHeader src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static XrHapticBaseHeader malloc()
Returns a newXrHapticBaseHeaderinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static XrHapticBaseHeader calloc()
Returns a newXrHapticBaseHeaderinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static XrHapticBaseHeader create()
Returns a newXrHapticBaseHeaderinstance allocated withBufferUtils.
-
create
public static XrHapticBaseHeader create(long address)
Returns a newXrHapticBaseHeaderinstance for the specified memory address.
-
createSafe
@Nullable public static XrHapticBaseHeader createSafe(long address)
-
create
public static XrHapticBaseHeader create(XrHapticVibration value)
Upcasts the specifiedXrHapticVibrationinstance toXrHapticBaseHeader.
-
malloc
public static XrHapticBaseHeader.Buffer malloc(int capacity)
Returns a newXrHapticBaseHeader.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static XrHapticBaseHeader.Buffer calloc(int capacity)
Returns a newXrHapticBaseHeader.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static XrHapticBaseHeader.Buffer create(int capacity)
Returns a newXrHapticBaseHeader.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static XrHapticBaseHeader.Buffer create(long address, int capacity)
Create aXrHapticBaseHeader.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static XrHapticBaseHeader.Buffer createSafe(long address, int capacity)
-
create
public static XrHapticBaseHeader.Buffer create(XrHapticVibration.Buffer value)
Upcasts the specifiedXrHapticVibration.Bufferinstance toXrHapticBaseHeader.Buffer.
-
malloc
public static XrHapticBaseHeader malloc(org.lwjgl.system.MemoryStack stack)
Returns a newXrHapticBaseHeaderinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
public static XrHapticBaseHeader calloc(org.lwjgl.system.MemoryStack stack)
Returns a newXrHapticBaseHeaderinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
public static XrHapticBaseHeader.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newXrHapticBaseHeader.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
calloc
public static XrHapticBaseHeader.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newXrHapticBaseHeader.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
ntype
public static int ntype(long struct)
Unsafe version oftype().
-
nnext
public static long nnext(long struct)
Unsafe version ofnext().
-
ntype
public static void ntype(long struct, int value)Unsafe version oftype.
-
nnext
public static void nnext(long struct, long value)Unsafe version ofnext.
-
-