Package org.lwjgl.openvr
Class VRTextureBounds
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.openvr.VRTextureBounds
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,org.lwjgl.system.NativeResource
,org.lwjgl.system.Pointer
public class VRTextureBounds extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResource
Allows the application to control what part of the provided texture will be used in the frame buffer.Layout
struct VRTextureBounds_t { float uMin; float vMin; float uMax; float vMax; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
VRTextureBounds.Buffer
An array ofVRTextureBounds
structs.
-
Constructor Summary
Constructors Constructor Description VRTextureBounds(java.nio.ByteBuffer container)
Creates aVRTextureBounds
instance at the current position of the specifiedByteBuffer
container.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static VRTextureBounds
calloc()
Returns a newVRTextureBounds
instance allocated withmemCalloc
.static VRTextureBounds.Buffer
calloc(int capacity)
Returns a newVRTextureBounds.Buffer
instance allocated withmemCalloc
.static VRTextureBounds
callocStack()
Returns a newVRTextureBounds
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static VRTextureBounds.Buffer
callocStack(int capacity)
Returns a newVRTextureBounds.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static VRTextureBounds.Buffer
callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVRTextureBounds.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static VRTextureBounds
callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVRTextureBounds
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static VRTextureBounds
create()
Returns a newVRTextureBounds
instance allocated withBufferUtils
.static VRTextureBounds.Buffer
create(int capacity)
Returns a newVRTextureBounds.Buffer
instance allocated withBufferUtils
.static VRTextureBounds
create(long address)
Returns a newVRTextureBounds
instance for the specified memory address.static VRTextureBounds.Buffer
create(long address, int capacity)
Create aVRTextureBounds.Buffer
instance at the specified memory.static VRTextureBounds
createSafe(long address)
static VRTextureBounds.Buffer
createSafe(long address, int capacity)
static VRTextureBounds
malloc()
Returns a newVRTextureBounds
instance allocated withmemAlloc
.static VRTextureBounds.Buffer
malloc(int capacity)
Returns a newVRTextureBounds.Buffer
instance allocated withmemAlloc
.static VRTextureBounds
mallocStack()
Returns a newVRTextureBounds
instance allocated on the thread-localMemoryStack
.static VRTextureBounds.Buffer
mallocStack(int capacity)
Returns a newVRTextureBounds.Buffer
instance allocated on the thread-localMemoryStack
.static VRTextureBounds.Buffer
mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVRTextureBounds.Buffer
instance allocated on the specifiedMemoryStack
.static VRTextureBounds
mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVRTextureBounds
instance allocated on the specifiedMemoryStack
.static float
nuMax(long struct)
Unsafe version ofuMax()
.static void
nuMax(long struct, float value)
Unsafe version ofuMax
.static float
nuMin(long struct)
Unsafe version ofuMin()
.static void
nuMin(long struct, float value)
Unsafe version ofuMin
.static float
nvMax(long struct)
Unsafe version ofvMax()
.static void
nvMax(long struct, float value)
Unsafe version ofvMax
.static float
nvMin(long struct)
Unsafe version ofvMin()
.static void
nvMin(long struct, float value)
Unsafe version ofvMin
.VRTextureBounds
set(float uMin, float vMin, float uMax, float vMax)
Initializes this struct with the specified values.VRTextureBounds
set(VRTextureBounds src)
Copies the specified struct data to this struct.int
sizeof()
float
uMax()
Returns the value of theuMax
field.VRTextureBounds
uMax(float value)
Sets the specified value to theuMax
field.float
uMin()
Returns the value of theuMin
field.VRTextureBounds
uMin(float value)
Sets the specified value to theuMin
field.float
vMax()
Returns the value of thevMax
field.VRTextureBounds
vMax(float value)
Sets the specified value to thevMax
field.float
vMin()
Returns the value of thevMin
field.VRTextureBounds
vMin(float value)
Sets the specified value to thevMin
field.
-
-
-
Constructor Detail
-
VRTextureBounds
public VRTextureBounds(java.nio.ByteBuffer container)
Creates aVRTextureBounds
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 Detail
-
sizeof
public int sizeof()
- Specified by:
sizeof
in classorg.lwjgl.system.Struct
-
uMin
public float uMin()
Returns the value of theuMin
field.
-
vMin
public float vMin()
Returns the value of thevMin
field.
-
uMax
public float uMax()
Returns the value of theuMax
field.
-
vMax
public float vMax()
Returns the value of thevMax
field.
-
uMin
public VRTextureBounds uMin(float value)
Sets the specified value to theuMin
field.
-
vMin
public VRTextureBounds vMin(float value)
Sets the specified value to thevMin
field.
-
uMax
public VRTextureBounds uMax(float value)
Sets the specified value to theuMax
field.
-
vMax
public VRTextureBounds vMax(float value)
Sets the specified value to thevMax
field.
-
set
public VRTextureBounds set(float uMin, float vMin, float uMax, float vMax)
Initializes this struct with the specified values.
-
set
public VRTextureBounds set(VRTextureBounds src)
Copies the specified struct data to this struct.- Parameters:
src
- the source struct- Returns:
- this struct
-
malloc
public static VRTextureBounds malloc()
Returns a newVRTextureBounds
instance allocated withmemAlloc
. The instance must be explicitly freed.
-
calloc
public static VRTextureBounds calloc()
Returns a newVRTextureBounds
instance allocated withmemCalloc
. The instance must be explicitly freed.
-
create
public static VRTextureBounds create()
Returns a newVRTextureBounds
instance allocated withBufferUtils
.
-
create
public static VRTextureBounds create(long address)
Returns a newVRTextureBounds
instance for the specified memory address.
-
createSafe
@Nullable public static VRTextureBounds createSafe(long address)
-
malloc
public static VRTextureBounds.Buffer malloc(int capacity)
Returns a newVRTextureBounds.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
public static VRTextureBounds.Buffer calloc(int capacity)
Returns a newVRTextureBounds.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
public static VRTextureBounds.Buffer create(int capacity)
Returns a newVRTextureBounds.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
public static VRTextureBounds.Buffer create(long address, int capacity)
Create aVRTextureBounds.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
@Nullable public static VRTextureBounds.Buffer createSafe(long address, int capacity)
-
mallocStack
public static VRTextureBounds mallocStack()
Returns a newVRTextureBounds
instance allocated on the thread-localMemoryStack
.
-
callocStack
public static VRTextureBounds callocStack()
Returns a newVRTextureBounds
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.
-
mallocStack
public static VRTextureBounds mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVRTextureBounds
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
callocStack
public static VRTextureBounds callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVRTextureBounds
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
mallocStack
public static VRTextureBounds.Buffer mallocStack(int capacity)
Returns a newVRTextureBounds.Buffer
instance allocated on the thread-localMemoryStack
.- Parameters:
capacity
- the buffer capacity
-
callocStack
public static VRTextureBounds.Buffer callocStack(int capacity)
Returns a newVRTextureBounds.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacity
-
mallocStack
public static VRTextureBounds.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVRTextureBounds.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
callocStack
public static VRTextureBounds.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVRTextureBounds.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
nuMin
public static float nuMin(long struct)
Unsafe version ofuMin()
.
-
nvMin
public static float nvMin(long struct)
Unsafe version ofvMin()
.
-
nuMax
public static float nuMax(long struct)
Unsafe version ofuMax()
.
-
nvMax
public static float nvMax(long struct)
Unsafe version ofvMax()
.
-
nuMin
public static void nuMin(long struct, float value)
Unsafe version ofuMin
.
-
nvMin
public static void nvMin(long struct, float value)
Unsafe version ofvMin
.
-
nuMax
public static void nuMax(long struct, float value)
Unsafe version ofuMax
.
-
nvMax
public static void nvMax(long struct, float value)
Unsafe version ofvMax
.
-
-