Package org.lwjgl.util.ktx
Class ktxStream.Buffer
- All Implemented Interfaces:
AutoCloseable
,Iterable<ktxStream>
,NativeResource
,Pointer
- Enclosing class:
ktxStream
public static class ktxStream.Buffer
extends StructBuffer<ktxStream,ktxStream.Buffer>
implements NativeResource
An array of
ktxStream
structs.-
Nested Class Summary
Nested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default
-
Field Summary
Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE
-
Constructor Summary
ConstructorsConstructorDescriptionBuffer
(long address, int cap) Buffer
(ByteBuffer container) Creates a newktxStream.Buffer
instance backed by the specified container. -
Method Summary
Modifier and TypeMethodDescriptionboolean
closeOnDestruct
(boolean value) Sets the specified value to thecloseOnDestruct
field.data_custom_ptr_address
(int capacity) Sets the address of the specifiedByteBuffer
to theaddress
field.long
data_custom_ptr_allocatorAddress
(long value) Sets the specified value to theallocatorAddress
field.long
data_custom_ptr_size
(long value) Sets the specified value to thesize
field.long
data_file
(long value) Sets the specified value to thefile
field.long
data_mem()
data_mem
(long value) Sets the specified value to themem
field.destruct()
destruct
(ktxStream_destructI value) Sets the specified value to thedestruct
field.getpos()
getpos
(ktxStream_getposI value) Sets the specified value to thegetpos
field.getsize()
getsize
(ktxStream_getsizeI value) Sets the specified value to thegetsize
field.read()
read
(ktxStream_readI value) Sets the specified value to theread
field.long
readpos()
readpos
(long value) Sets the specified value to thereadpos
field.setpos()
setpos
(ktxStream_setposI value) Sets the specified value to thesetpos
field.skip()
skip
(ktxStream_skipI value) Sets the specified value to theskip
field.int
type()
type
(int value) Sets the specified value to thetype
field.write()
write
(ktxStream_writeI value) Sets the specified value to thewrite
field.Methods inherited from class org.lwjgl.system.StructBuffer
apply, apply, forEach, get, get, get, get, iterator, parallelStream, put, put, sizeof, spliterator, stream
Methods inherited from class org.lwjgl.system.CustomBuffer
address, address, address0, capacity, clear, compact, duplicate, flip, free, hasRemaining, limit, limit, mark, position, position, put, remaining, reset, rewind, slice, slice, toString
Methods inherited from class org.lwjgl.system.Pointer.Default
equals, hashCode
Methods inherited from interface org.lwjgl.system.NativeResource
close, free
-
Constructor Details
-
Buffer
Creates a newktxStream.Buffer
instance backed by the specified container.Changes to the container's content will be visible to the struct buffer instance and vice versa. The two buffers' position, limit, and mark values will be independent. The new buffer's position will be zero, its capacity and its limit will be the number of bytes remaining in this buffer divided by
ktxStream.SIZEOF
, and its mark will be undefined.The created buffer instance holds a strong reference to the container object.
-
Buffer
public Buffer(long address, int cap)
-
-
Method Details
-
read
- Returns:
- the value of the
read
field.
-
skip
- Returns:
- the value of the
skip
field.
-
write
- Returns:
- the value of the
write
field.
-
getpos
- Returns:
- the value of the
getpos
field.
-
setpos
- Returns:
- the value of the
setpos
field.
-
getsize
- Returns:
- the value of the
getsize
field.
-
destruct
- Returns:
- the value of the
destruct
field.
-
type
public int type()- Returns:
- the value of the
type
field.
-
data_file
public long data_file()- Returns:
- the value of the
data.file
field.
-
data_mem
public long data_mem()- Returns:
- the value of the
data.mem
field.
-
data_custom_ptr_address
- Returns:
- a
ByteBuffer
view of the data pointed to by thedata.custom_ptr.address
field.
-
data_custom_ptr_allocatorAddress
public long data_custom_ptr_allocatorAddress()- Returns:
- the value of the
data.custom_ptr.allocatorAddress
field.
-
data_custom_ptr_size
public long data_custom_ptr_size()- Returns:
- the value of the
data.custom_ptr.size
field.
-
readpos
public long readpos()- Returns:
- the value of the
readpos
field.
-
closeOnDestruct
public boolean closeOnDestruct()- Returns:
- the value of the
closeOnDestruct
field.
-
read
Sets the specified value to theread
field. -
skip
Sets the specified value to theskip
field. -
write
Sets the specified value to thewrite
field. -
getpos
Sets the specified value to thegetpos
field. -
setpos
Sets the specified value to thesetpos
field. -
getsize
Sets the specified value to thegetsize
field. -
destruct
Sets the specified value to thedestruct
field. -
type
Sets the specified value to thetype
field. -
data_file
Sets the specified value to thefile
field. -
data_mem
Sets the specified value to themem
field. -
data_custom_ptr_address
Sets the address of the specifiedByteBuffer
to theaddress
field. -
data_custom_ptr_allocatorAddress
Sets the specified value to theallocatorAddress
field. -
data_custom_ptr_size
Sets the specified value to thesize
field. -
readpos
Sets the specified value to thereadpos
field. -
closeOnDestruct
Sets the specified value to thecloseOnDestruct
field.
-