public class UIVec2
extends org.lwjgl.system.Struct
implements org.lwjgl.system.NativeResource
struct UIvec2 {
union {
int v[2];
struct {
int x;
int y;
};
};
}| Modifier and Type | Class and Description |
|---|---|
static class |
UIVec2.Buffer
An array of
UIVec2 structs. |
| Modifier and Type | Field and Description |
|---|---|
static int |
ALIGNOF
The struct alignment in bytes.
|
static int |
SIZEOF
The struct size in bytes.
|
static int |
V
The struct member offsets.
|
static int |
X
The struct member offsets.
|
static int |
Y
The struct member offsets.
|
| Constructor and Description |
|---|
UIVec2(java.nio.ByteBuffer container)
Creates a
UIVec2 instance at the current position of the specified ByteBuffer container. |
| Modifier and Type | Method and Description |
|---|---|
static UIVec2 |
calloc()
Returns a new
UIVec2 instance allocated with memCalloc. |
static UIVec2.Buffer |
calloc(int capacity)
Returns a new
UIVec2.Buffer instance allocated with memCalloc. |
static UIVec2 |
callocStack()
Returns a new
UIVec2 instance allocated on the thread-local MemoryStack and initializes all its bits to zero. |
static UIVec2.Buffer |
callocStack(int capacity)
Returns a new
UIVec2.Buffer instance allocated on the thread-local MemoryStack and initializes all its bits to zero. |
static UIVec2.Buffer |
callocStack(int capacity,
org.lwjgl.system.MemoryStack stack)
Returns a new
UIVec2.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero. |
static UIVec2 |
callocStack(org.lwjgl.system.MemoryStack stack)
Returns a new
UIVec2 instance allocated on the specified MemoryStack and initializes all its bits to zero. |
static UIVec2 |
create()
Returns a new
UIVec2 instance allocated with BufferUtils. |
static UIVec2.Buffer |
create(int capacity)
Returns a new
UIVec2.Buffer instance allocated with BufferUtils. |
static UIVec2 |
create(long address)
Returns a new
UIVec2 instance for the specified memory address. |
static UIVec2.Buffer |
create(long address,
int capacity)
Create a
UIVec2.Buffer instance at the specified memory. |
static UIVec2 |
createSafe(long address)
|
static UIVec2.Buffer |
createSafe(long address,
int capacity)
|
static UIVec2 |
malloc()
Returns a new
UIVec2 instance allocated with memAlloc. |
static UIVec2.Buffer |
malloc(int capacity)
Returns a new
UIVec2.Buffer instance allocated with memAlloc. |
static UIVec2 |
mallocStack()
Returns a new
UIVec2 instance allocated on the thread-local MemoryStack. |
static UIVec2.Buffer |
mallocStack(int capacity)
Returns a new
UIVec2.Buffer instance allocated on the thread-local MemoryStack. |
static UIVec2.Buffer |
mallocStack(int capacity,
org.lwjgl.system.MemoryStack stack)
Returns a new
UIVec2.Buffer instance allocated on the specified MemoryStack. |
static UIVec2 |
mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a new
UIVec2 instance allocated on the specified MemoryStack. |
static java.nio.IntBuffer |
nv(long struct)
Unsafe version of
v(). |
static int |
nv(long struct,
int index)
Unsafe version of
v. |
static void |
nv(long struct,
java.nio.IntBuffer value)
Unsafe version of
v. |
static void |
nv(long struct,
int index,
int value)
Unsafe version of
v. |
static int |
nx(long struct)
Unsafe version of
x(). |
static void |
nx(long struct,
int value)
Unsafe version of
x. |
static int |
ny(long struct)
Unsafe version of
y(). |
static void |
ny(long struct,
int value)
Unsafe version of
y. |
UIVec2 |
set(UIVec2 src)
Copies the specified struct data to this struct.
|
int |
sizeof() |
java.nio.IntBuffer |
v()
Returns a
IntBuffer view of the v field. |
int |
v(int index)
Returns the value at the specified index of the
v field. |
UIVec2 |
v(java.nio.IntBuffer value)
Copies the specified
IntBuffer to the v field. |
UIVec2 |
v(int index,
int value)
Sets the specified value at the specified index of the
v field. |
int |
x()
Returns the value of the
x field. |
UIVec2 |
x(int value)
Sets the specified value to the
x field. |
int |
y()
Returns the value of the
y field. |
UIVec2 |
y(int value)
Sets the specified value to the
y field. |
public static final int SIZEOF
public static final int ALIGNOF
public static final int V
public static final int X
public static final int Y
public UIVec2(java.nio.ByteBuffer container)
UIVec2 instance at the current position of the specified ByteBuffer 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.
public int sizeof()
sizeof in class org.lwjgl.system.Structpublic java.nio.IntBuffer v()
IntBuffer view of the v field.public int v(int index)
v field.public int x()
x field.public int y()
y field.public UIVec2 v(java.nio.IntBuffer value)
IntBuffer to the v field.public UIVec2 v(int index, int value)
v field.public UIVec2 x(int value)
x field.public UIVec2 y(int value)
y field.public UIVec2 set(UIVec2 src)
src - the source structpublic static UIVec2 malloc()
UIVec2 instance allocated with memAlloc. The instance must be explicitly freed.public static UIVec2 calloc()
UIVec2 instance allocated with memCalloc. The instance must be explicitly freed.public static UIVec2 create()
UIVec2 instance allocated with BufferUtils.public static UIVec2 create(long address)
UIVec2 instance for the specified memory address.@Nullable public static UIVec2 createSafe(long address)
public static UIVec2.Buffer malloc(int capacity)
UIVec2.Buffer instance allocated with memAlloc. The instance must be explicitly freed.capacity - the buffer capacitypublic static UIVec2.Buffer calloc(int capacity)
UIVec2.Buffer instance allocated with memCalloc. The instance must be explicitly freed.capacity - the buffer capacitypublic static UIVec2.Buffer create(int capacity)
UIVec2.Buffer instance allocated with BufferUtils.capacity - the buffer capacitypublic static UIVec2.Buffer create(long address, int capacity)
UIVec2.Buffer instance at the specified memory.address - the memory addresscapacity - the buffer capacity@Nullable public static UIVec2.Buffer createSafe(long address, int capacity)
public static UIVec2 mallocStack()
UIVec2 instance allocated on the thread-local MemoryStack.public static UIVec2 callocStack()
UIVec2 instance allocated on the thread-local MemoryStack and initializes all its bits to zero.public static UIVec2 mallocStack(org.lwjgl.system.MemoryStack stack)
UIVec2 instance allocated on the specified MemoryStack.stack - the stack from which to allocatepublic static UIVec2 callocStack(org.lwjgl.system.MemoryStack stack)
UIVec2 instance allocated on the specified MemoryStack and initializes all its bits to zero.stack - the stack from which to allocatepublic static UIVec2.Buffer mallocStack(int capacity)
UIVec2.Buffer instance allocated on the thread-local MemoryStack.capacity - the buffer capacitypublic static UIVec2.Buffer callocStack(int capacity)
UIVec2.Buffer instance allocated on the thread-local MemoryStack and initializes all its bits to zero.capacity - the buffer capacitypublic static UIVec2.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
UIVec2.Buffer instance allocated on the specified MemoryStack.stack - the stack from which to allocatecapacity - the buffer capacitypublic static UIVec2.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
UIVec2.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.stack - the stack from which to allocatecapacity - the buffer capacitypublic static java.nio.IntBuffer nv(long struct)
v().public static int nv(long struct,
int index)
v.public static int nx(long struct)
x().public static int ny(long struct)
y().public static void nv(long struct,
java.nio.IntBuffer value)
v.public static void nv(long struct,
int index,
int value)
v.public static void nx(long struct,
int value)
x.public static void ny(long struct,
int value)
y.Copyright LWJGL. All Rights Reserved. License terms.