Package org.lwjgl.openvr
Class HmdRect2
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.openvr.HmdRect2
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class HmdRect2 extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceLayout
struct HmdRect2_t {HmdVector2_tvTopLeft;HmdVector2_tvBottomRight; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classHmdRect2.BufferAn array ofHmdRect2structs.
-
Field Summary
Fields Modifier and Type Field Description static intALIGNOFThe struct alignment in bytes.static intSIZEOFThe struct size in bytes.static intVBOTTOMRIGHT
VTOPLEFTThe struct member offsets.
-
Constructor Summary
Constructors Constructor Description HmdRect2(java.nio.ByteBuffer container)Creates aHmdRect2instance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static HmdRect2calloc()Returns a newHmdRect2instance allocated withmemCalloc.static HmdRect2.Buffercalloc(int capacity)Returns a newHmdRect2.Bufferinstance allocated withmemCalloc.static HmdRect2callocStack()Returns a newHmdRect2instance allocated on the thread-localMemoryStackand initializes all its bits to zero.static HmdRect2.BuffercallocStack(int capacity)Returns a newHmdRect2.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.static HmdRect2.BuffercallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newHmdRect2.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static HmdRect2callocStack(org.lwjgl.system.MemoryStack stack)Returns a newHmdRect2instance allocated on the specifiedMemoryStackand initializes all its bits to zero.static HmdRect2create()Returns a newHmdRect2instance allocated withBufferUtils.static HmdRect2.Buffercreate(int capacity)Returns a newHmdRect2.Bufferinstance allocated withBufferUtils.static HmdRect2create(long address)Returns a newHmdRect2instance for the specified memory address.static HmdRect2.Buffercreate(long address, int capacity)Create aHmdRect2.Bufferinstance at the specified memory.static HmdRect2createSafe(long address)static HmdRect2.BuffercreateSafe(long address, int capacity)static HmdRect2malloc()Returns a newHmdRect2instance allocated withmemAlloc.static HmdRect2.Buffermalloc(int capacity)Returns a newHmdRect2.Bufferinstance allocated withmemAlloc.static HmdRect2mallocStack()Returns a newHmdRect2instance allocated on the thread-localMemoryStack.static HmdRect2.BuffermallocStack(int capacity)Returns a newHmdRect2.Bufferinstance allocated on the thread-localMemoryStack.static HmdRect2.BuffermallocStack(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newHmdRect2.Bufferinstance allocated on the specifiedMemoryStack.static HmdRect2mallocStack(org.lwjgl.system.MemoryStack stack)Returns a newHmdRect2instance allocated on the specifiedMemoryStack.static HmdVector2nvBottomRight(long struct)Unsafe version ofvBottomRight().static voidnvBottomRight(long struct, HmdVector2 value)Unsafe version ofvBottomRight.static HmdVector2nvTopLeft(long struct)Unsafe version ofvTopLeft().static voidnvTopLeft(long struct, HmdVector2 value)Unsafe version ofvTopLeft.HmdRect2set(HmdRect2 src)Copies the specified struct data to this struct.HmdRect2set(HmdVector2 vTopLeft, HmdVector2 vBottomRight)Initializes this struct with the specified values.intsizeof()HmdVector2vBottomRight()Returns aHmdVector2view of thevBottomRightfield.HmdRect2vBottomRight(java.util.function.Consumer<HmdVector2> consumer)Passes thevBottomRightfield to the specifiedConsumer.HmdRect2vBottomRight(HmdVector2 value)Copies the specifiedHmdVector2to thevBottomRightfield.HmdVector2vTopLeft()Returns aHmdVector2view of thevTopLeftfield.HmdRect2vTopLeft(java.util.function.Consumer<HmdVector2> consumer)Passes thevTopLeftfield to the specifiedConsumer.HmdRect2vTopLeft(HmdVector2 value)Copies the specifiedHmdVector2to thevTopLeftfield.
-
-
-
Constructor Detail
-
HmdRect2
public HmdRect2(java.nio.ByteBuffer container)
Creates aHmdRect2instance 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
-
vTopLeft
public HmdVector2 vTopLeft()
Returns aHmdVector2view of thevTopLeftfield.
-
vBottomRight
public HmdVector2 vBottomRight()
Returns aHmdVector2view of thevBottomRightfield.
-
vTopLeft
public HmdRect2 vTopLeft(HmdVector2 value)
Copies the specifiedHmdVector2to thevTopLeftfield.
-
vTopLeft
public HmdRect2 vTopLeft(java.util.function.Consumer<HmdVector2> consumer)
Passes thevTopLeftfield to the specifiedConsumer.
-
vBottomRight
public HmdRect2 vBottomRight(HmdVector2 value)
Copies the specifiedHmdVector2to thevBottomRightfield.
-
vBottomRight
public HmdRect2 vBottomRight(java.util.function.Consumer<HmdVector2> consumer)
Passes thevBottomRightfield to the specifiedConsumer.
-
set
public HmdRect2 set(HmdVector2 vTopLeft, HmdVector2 vBottomRight)
Initializes this struct with the specified values.
-
set
public HmdRect2 set(HmdRect2 src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static HmdRect2 malloc()
Returns a newHmdRect2instance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static HmdRect2 calloc()
Returns a newHmdRect2instance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static HmdRect2 create()
Returns a newHmdRect2instance allocated withBufferUtils.
-
create
public static HmdRect2 create(long address)
Returns a newHmdRect2instance for the specified memory address.
-
createSafe
@Nullable public static HmdRect2 createSafe(long address)
-
malloc
public static HmdRect2.Buffer malloc(int capacity)
Returns a newHmdRect2.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static HmdRect2.Buffer calloc(int capacity)
Returns a newHmdRect2.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static HmdRect2.Buffer create(int capacity)
Returns a newHmdRect2.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static HmdRect2.Buffer create(long address, int capacity)
Create aHmdRect2.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static HmdRect2.Buffer createSafe(long address, int capacity)
-
mallocStack
public static HmdRect2 mallocStack()
Returns a newHmdRect2instance allocated on the thread-localMemoryStack.
-
callocStack
public static HmdRect2 callocStack()
Returns a newHmdRect2instance allocated on the thread-localMemoryStackand initializes all its bits to zero.
-
mallocStack
public static HmdRect2 mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newHmdRect2instance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
callocStack
public static HmdRect2 callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newHmdRect2instance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
mallocStack
public static HmdRect2.Buffer mallocStack(int capacity)
Returns a newHmdRect2.Bufferinstance allocated on the thread-localMemoryStack.- Parameters:
capacity- the buffer capacity
-
callocStack
public static HmdRect2.Buffer callocStack(int capacity)
Returns a newHmdRect2.Bufferinstance allocated on the thread-localMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacity
-
mallocStack
public static HmdRect2.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newHmdRect2.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
callocStack
public static HmdRect2.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newHmdRect2.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
nvTopLeft
public static HmdVector2 nvTopLeft(long struct)
Unsafe version ofvTopLeft().
-
nvBottomRight
public static HmdVector2 nvBottomRight(long struct)
Unsafe version ofvBottomRight().
-
nvTopLeft
public static void nvTopLeft(long struct, HmdVector2 value)Unsafe version ofvTopLeft.
-
nvBottomRight
public static void nvBottomRight(long struct, HmdVector2 value)Unsafe version ofvBottomRight.
-
-