Package org.lwjgl.util.spvc
Class SpvcBufferRange
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.util.spvc.SpvcBufferRange
-
- All Implemented Interfaces:
java.lang.AutoCloseable,org.lwjgl.system.NativeResource,org.lwjgl.system.Pointer
public class SpvcBufferRange extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResourceLayout
struct spvc_buffer_range { unsigned int index; size_t offset; size_t range; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classSpvcBufferRange.BufferAn array ofSpvcBufferRangestructs.
-
Constructor Summary
Constructors Constructor Description SpvcBufferRange(java.nio.ByteBuffer container)Creates aSpvcBufferRangeinstance at the current position of the specifiedByteBuffercontainer.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static SpvcBufferRangecalloc()Returns a newSpvcBufferRangeinstance allocated withmemCalloc.static SpvcBufferRange.Buffercalloc(int capacity)Returns a newSpvcBufferRange.Bufferinstance allocated withmemCalloc.static SpvcBufferRange.Buffercalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newSpvcBufferRange.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static SpvcBufferRangecalloc(org.lwjgl.system.MemoryStack stack)Returns a newSpvcBufferRangeinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static SpvcBufferRangecreate()Returns a newSpvcBufferRangeinstance allocated withBufferUtils.static SpvcBufferRange.Buffercreate(int capacity)Returns a newSpvcBufferRange.Bufferinstance allocated withBufferUtils.static SpvcBufferRangecreate(long address)Returns a newSpvcBufferRangeinstance for the specified memory address.static SpvcBufferRange.Buffercreate(long address, int capacity)Create aSpvcBufferRange.Bufferinstance at the specified memory.static SpvcBufferRangecreateSafe(long address)static SpvcBufferRange.BuffercreateSafe(long address, int capacity)intindex()SpvcBufferRangeindex(int value)Sets the specified value to theindexfield.static SpvcBufferRangemalloc()Returns a newSpvcBufferRangeinstance allocated withmemAlloc.static SpvcBufferRange.Buffermalloc(int capacity)Returns a newSpvcBufferRange.Bufferinstance allocated withmemAlloc.static SpvcBufferRange.Buffermalloc(int capacity, org.lwjgl.system.MemoryStack stack)Returns a newSpvcBufferRange.Bufferinstance allocated on the specifiedMemoryStack.static SpvcBufferRangemalloc(org.lwjgl.system.MemoryStack stack)Returns a newSpvcBufferRangeinstance allocated on the specifiedMemoryStack.static intnindex(long struct)Unsafe version ofindex().static voidnindex(long struct, int value)Unsafe version ofindex.static longnoffset(long struct)Unsafe version ofoffset().static voidnoffset(long struct, long value)Unsafe version ofoffset.static longnrange(long struct)Unsafe version ofrange().static voidnrange(long struct, long value)Unsafe version ofrange.longoffset()SpvcBufferRangeoffset(long value)Sets the specified value to theoffsetfield.longrange()SpvcBufferRangerange(long value)Sets the specified value to therangefield.SpvcBufferRangeset(int index, long offset, long range)Initializes this struct with the specified values.SpvcBufferRangeset(SpvcBufferRange src)Copies the specified struct data to this struct.intsizeof()
-
-
-
Constructor Detail
-
SpvcBufferRange
public SpvcBufferRange(java.nio.ByteBuffer container)
Creates aSpvcBufferRangeinstance 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
-
index
public int index()
- Returns:
- the value of the
indexfield.
-
offset
public long offset()
- Returns:
- the value of the
offsetfield.
-
range
public long range()
- Returns:
- the value of the
rangefield.
-
index
public SpvcBufferRange index(int value)
Sets the specified value to theindexfield.
-
offset
public SpvcBufferRange offset(long value)
Sets the specified value to theoffsetfield.
-
range
public SpvcBufferRange range(long value)
Sets the specified value to therangefield.
-
set
public SpvcBufferRange set(int index, long offset, long range)
Initializes this struct with the specified values.
-
set
public SpvcBufferRange set(SpvcBufferRange src)
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
public static SpvcBufferRange malloc()
Returns a newSpvcBufferRangeinstance allocated withmemAlloc. The instance must be explicitly freed.
-
calloc
public static SpvcBufferRange calloc()
Returns a newSpvcBufferRangeinstance allocated withmemCalloc. The instance must be explicitly freed.
-
create
public static SpvcBufferRange create()
Returns a newSpvcBufferRangeinstance allocated withBufferUtils.
-
create
public static SpvcBufferRange create(long address)
Returns a newSpvcBufferRangeinstance for the specified memory address.
-
createSafe
@Nullable public static SpvcBufferRange createSafe(long address)
-
malloc
public static SpvcBufferRange.Buffer malloc(int capacity)
Returns a newSpvcBufferRange.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
public static SpvcBufferRange.Buffer calloc(int capacity)
Returns a newSpvcBufferRange.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
public static SpvcBufferRange.Buffer create(int capacity)
Returns a newSpvcBufferRange.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
public static SpvcBufferRange.Buffer create(long address, int capacity)
Create aSpvcBufferRange.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
@Nullable public static SpvcBufferRange.Buffer createSafe(long address, int capacity)
-
malloc
public static SpvcBufferRange malloc(org.lwjgl.system.MemoryStack stack)
Returns a newSpvcBufferRangeinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
public static SpvcBufferRange calloc(org.lwjgl.system.MemoryStack stack)
Returns a newSpvcBufferRangeinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
public static SpvcBufferRange.Buffer malloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newSpvcBufferRange.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
calloc
public static SpvcBufferRange.Buffer calloc(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newSpvcBufferRange.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocatecapacity- the buffer capacity
-
nindex
public static int nindex(long struct)
Unsafe version ofindex().
-
noffset
public static long noffset(long struct)
Unsafe version ofoffset().
-
nrange
public static long nrange(long struct)
Unsafe version ofrange().
-
nindex
public static void nindex(long struct, int value)Unsafe version ofindex.
-
noffset
public static void noffset(long struct, long value)Unsafe version ofoffset.
-
nrange
public static void nrange(long struct, long value)Unsafe version ofrange.
-
-