Package org.lwjgl.bgfx
Class BGFXTransientIndexBuffer
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.bgfx.BGFXTransientIndexBuffer
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,org.lwjgl.system.NativeResource
,org.lwjgl.system.Pointer
public class BGFXTransientIndexBuffer extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResource
Transient index buffer.Member documentation
data
– pointer to datasize
– data sizestartIndex
– first indexhandle
– index buffer handle
Layout
struct bgfx_transient_index_buffer_t { uint8_t * data; uint32_t size; uint32_t startIndex; bgfx_index_buffer_handle_t handle; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
BGFXTransientIndexBuffer.Buffer
An array ofBGFXTransientIndexBuffer
structs.
-
Constructor Summary
Constructors Constructor Description BGFXTransientIndexBuffer(java.nio.ByteBuffer container)
Creates aBGFXTransientIndexBuffer
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 BGFXTransientIndexBuffer
calloc()
Returns a newBGFXTransientIndexBuffer
instance allocated withmemCalloc
.static BGFXTransientIndexBuffer.Buffer
calloc(int capacity)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated withmemCalloc
.static BGFXTransientIndexBuffer
callocStack()
Returns a newBGFXTransientIndexBuffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static BGFXTransientIndexBuffer.Buffer
callocStack(int capacity)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static BGFXTransientIndexBuffer.Buffer
callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static BGFXTransientIndexBuffer
callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newBGFXTransientIndexBuffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static BGFXTransientIndexBuffer
create()
Returns a newBGFXTransientIndexBuffer
instance allocated withBufferUtils
.static BGFXTransientIndexBuffer.Buffer
create(int capacity)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated withBufferUtils
.static BGFXTransientIndexBuffer
create(long address)
Returns a newBGFXTransientIndexBuffer
instance for the specified memory address.static BGFXTransientIndexBuffer.Buffer
create(long address, int capacity)
Create aBGFXTransientIndexBuffer.Buffer
instance at the specified memory.static BGFXTransientIndexBuffer
createSafe(long address)
static BGFXTransientIndexBuffer.Buffer
createSafe(long address, int capacity)
java.nio.ByteBuffer
data()
Returns aByteBuffer
view of the data pointed to by thedata
field.BGFXTransientIndexBuffer
data(java.nio.ByteBuffer value)
Sets the address of the specifiedByteBuffer
to thedata
field.short
handle()
Returns the value of thehandle
field.BGFXTransientIndexBuffer
handle(short value)
Sets the specified value to thehandle
field.static BGFXTransientIndexBuffer
malloc()
Returns a newBGFXTransientIndexBuffer
instance allocated withmemAlloc
.static BGFXTransientIndexBuffer.Buffer
malloc(int capacity)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated withmemAlloc
.static BGFXTransientIndexBuffer
mallocStack()
Returns a newBGFXTransientIndexBuffer
instance allocated on the thread-localMemoryStack
.static BGFXTransientIndexBuffer.Buffer
mallocStack(int capacity)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated on the thread-localMemoryStack
.static BGFXTransientIndexBuffer.Buffer
mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated on the specifiedMemoryStack
.static BGFXTransientIndexBuffer
mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newBGFXTransientIndexBuffer
instance allocated on the specifiedMemoryStack
.static java.nio.ByteBuffer
ndata(long struct)
Unsafe version ofdata
.static void
ndata(long struct, java.nio.ByteBuffer value)
Unsafe version ofdata
.static short
nhandle(long struct)
Unsafe version ofhandle()
.static void
nhandle(long struct, short value)
Unsafe version ofhandle
.static int
nsize(long struct)
Unsafe version ofsize()
.static void
nsize(long struct, int value)
Sets the specified value to thesize
field of the specifiedstruct
.static int
nstartIndex(long struct)
Unsafe version ofstartIndex()
.static void
nstartIndex(long struct, int value)
Unsafe version ofstartIndex
.BGFXTransientIndexBuffer
set(java.nio.ByteBuffer data, int startIndex, short handle)
Initializes this struct with the specified values.BGFXTransientIndexBuffer
set(BGFXTransientIndexBuffer src)
Copies the specified struct data to this struct.int
size()
Returns the value of thesize
field.int
sizeof()
int
startIndex()
Returns the value of thestartIndex
field.BGFXTransientIndexBuffer
startIndex(int value)
Sets the specified value to thestartIndex
field.static void
validate(long struct)
Validates pointer members that should not beNULL
.static void
validate(long array, int count)
Callsvalidate(long)
for each struct contained in the specified struct array.
-
-
-
Constructor Detail
-
BGFXTransientIndexBuffer
public BGFXTransientIndexBuffer(java.nio.ByteBuffer container)
Creates aBGFXTransientIndexBuffer
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
-
data
public java.nio.ByteBuffer data()
Returns aByteBuffer
view of the data pointed to by thedata
field.
-
size
public int size()
Returns the value of thesize
field.
-
startIndex
public int startIndex()
Returns the value of thestartIndex
field.
-
handle
public short handle()
Returns the value of thehandle
field.
-
data
public BGFXTransientIndexBuffer data(java.nio.ByteBuffer value)
Sets the address of the specifiedByteBuffer
to thedata
field.
-
startIndex
public BGFXTransientIndexBuffer startIndex(int value)
Sets the specified value to thestartIndex
field.
-
handle
public BGFXTransientIndexBuffer handle(short value)
Sets the specified value to thehandle
field.
-
set
public BGFXTransientIndexBuffer set(java.nio.ByteBuffer data, int startIndex, short handle)
Initializes this struct with the specified values.
-
set
public BGFXTransientIndexBuffer set(BGFXTransientIndexBuffer src)
Copies the specified struct data to this struct.- Parameters:
src
- the source struct- Returns:
- this struct
-
malloc
public static BGFXTransientIndexBuffer malloc()
Returns a newBGFXTransientIndexBuffer
instance allocated withmemAlloc
. The instance must be explicitly freed.
-
calloc
public static BGFXTransientIndexBuffer calloc()
Returns a newBGFXTransientIndexBuffer
instance allocated withmemCalloc
. The instance must be explicitly freed.
-
create
public static BGFXTransientIndexBuffer create()
Returns a newBGFXTransientIndexBuffer
instance allocated withBufferUtils
.
-
create
public static BGFXTransientIndexBuffer create(long address)
Returns a newBGFXTransientIndexBuffer
instance for the specified memory address.
-
createSafe
@Nullable public static BGFXTransientIndexBuffer createSafe(long address)
-
malloc
public static BGFXTransientIndexBuffer.Buffer malloc(int capacity)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
public static BGFXTransientIndexBuffer.Buffer calloc(int capacity)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
public static BGFXTransientIndexBuffer.Buffer create(int capacity)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
public static BGFXTransientIndexBuffer.Buffer create(long address, int capacity)
Create aBGFXTransientIndexBuffer.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
@Nullable public static BGFXTransientIndexBuffer.Buffer createSafe(long address, int capacity)
-
mallocStack
public static BGFXTransientIndexBuffer mallocStack()
Returns a newBGFXTransientIndexBuffer
instance allocated on the thread-localMemoryStack
.
-
callocStack
public static BGFXTransientIndexBuffer callocStack()
Returns a newBGFXTransientIndexBuffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.
-
mallocStack
public static BGFXTransientIndexBuffer mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newBGFXTransientIndexBuffer
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
callocStack
public static BGFXTransientIndexBuffer callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newBGFXTransientIndexBuffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
mallocStack
public static BGFXTransientIndexBuffer.Buffer mallocStack(int capacity)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated on the thread-localMemoryStack
.- Parameters:
capacity
- the buffer capacity
-
callocStack
public static BGFXTransientIndexBuffer.Buffer callocStack(int capacity)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacity
-
mallocStack
public static BGFXTransientIndexBuffer.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
callocStack
public static BGFXTransientIndexBuffer.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newBGFXTransientIndexBuffer.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
ndata
public static java.nio.ByteBuffer ndata(long struct)
Unsafe version ofdata
.
-
nsize
public static int nsize(long struct)
Unsafe version ofsize()
.
-
nstartIndex
public static int nstartIndex(long struct)
Unsafe version ofstartIndex()
.
-
nhandle
public static short nhandle(long struct)
Unsafe version ofhandle()
.
-
ndata
public static void ndata(long struct, java.nio.ByteBuffer value)
Unsafe version ofdata
.
-
nsize
public static void nsize(long struct, int value)
Sets the specified value to thesize
field of the specifiedstruct
.
-
nstartIndex
public static void nstartIndex(long struct, int value)
Unsafe version ofstartIndex
.
-
nhandle
public static void nhandle(long struct, short value)
Unsafe version ofhandle
.
-
validate
public static void validate(long struct)
Validates pointer members that should not beNULL
.- Parameters:
struct
- the struct to validate
-
validate
public static void validate(long array, int count)
Callsvalidate(long)
for each struct contained in the specified struct array.- Parameters:
array
- the struct array to validatecount
- the number of structs inarray
-
-