Package org.lwjgl.sdl
Class SDL_GPUIndirectDrawCommand
- All Implemented Interfaces:
AutoCloseable,NativeResource,Pointer
public class SDL_GPUIndirectDrawCommand
extends Struct<SDL_GPUIndirectDrawCommand>
implements NativeResource
struct SDL_GPUIndirectDrawCommand {
Uint32 num_vertices;
Uint32 num_instances;
Uint32 first_vertex;
Uint32 first_instance;
}-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class org.lwjgl.system.Struct
Struct.StructValidationNested classes/interfaces inherited from interface org.lwjgl.system.Pointer
Pointer.Default -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intThe struct alignment in bytes.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct member offsets.static final intThe struct size in bytes.Fields inherited from interface org.lwjgl.system.Pointer
BITS32, BITS64, CLONG_SHIFT, CLONG_SIZE, POINTER_SHIFT, POINTER_SIZE -
Constructor Summary
ConstructorsConstructorDescriptionSDL_GPUIndirectDrawCommand(ByteBuffer container) Creates aSDL_GPUIndirectDrawCommandinstance at the current position of the specifiedByteBuffercontainer. -
Method Summary
Modifier and TypeMethodDescriptionstatic SDL_GPUIndirectDrawCommandcalloc()Returns a newSDL_GPUIndirectDrawCommandinstance allocated withmemCalloc.calloc(int capacity) Returns a newSDL_GPUIndirectDrawCommand.Bufferinstance allocated withmemCalloc.calloc(int capacity, MemoryStack stack) Returns a newSDL_GPUIndirectDrawCommand.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static SDL_GPUIndirectDrawCommandcalloc(MemoryStack stack) Returns a newSDL_GPUIndirectDrawCommandinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.static SDL_GPUIndirectDrawCommandcreate()Returns a newSDL_GPUIndirectDrawCommandinstance allocated withBufferUtils.create(int capacity) Returns a newSDL_GPUIndirectDrawCommand.Bufferinstance allocated withBufferUtils.static SDL_GPUIndirectDrawCommandcreate(long address) Returns a newSDL_GPUIndirectDrawCommandinstance for the specified memory address.create(long address, int capacity) Create aSDL_GPUIndirectDrawCommand.Bufferinstance at the specified memory.static @Nullable SDL_GPUIndirectDrawCommandcreateSafe(long address) static @Nullable SDL_GPUIndirectDrawCommand.BuffercreateSafe(long address, int capacity) intfirst_instance(int value) Sets the specified value to thefirst_instancefield.intfirst_vertex(int value) Sets the specified value to thefirst_vertexfield.static SDL_GPUIndirectDrawCommandmalloc()Returns a newSDL_GPUIndirectDrawCommandinstance allocated withmemAlloc.malloc(int capacity) Returns a newSDL_GPUIndirectDrawCommand.Bufferinstance allocated withmemAlloc.malloc(int capacity, MemoryStack stack) Returns a newSDL_GPUIndirectDrawCommand.Bufferinstance allocated on the specifiedMemoryStack.static SDL_GPUIndirectDrawCommandmalloc(MemoryStack stack) Returns a newSDL_GPUIndirectDrawCommandinstance allocated on the specifiedMemoryStack.static intnfirst_instance(long struct) Unsafe version offirst_instance().static voidnfirst_instance(long struct, int value) Unsafe version offirst_instance.static intnfirst_vertex(long struct) Unsafe version offirst_vertex().static voidnfirst_vertex(long struct, int value) Unsafe version offirst_vertex.static intnnum_instances(long struct) Unsafe version ofnum_instances().static voidnnum_instances(long struct, int value) Unsafe version ofnum_instances.static intnnum_vertices(long struct) Unsafe version ofnum_vertices().static voidnnum_vertices(long struct, int value) Unsafe version ofnum_vertices.intnum_instances(int value) Sets the specified value to thenum_instancesfield.intnum_vertices(int value) Sets the specified value to thenum_verticesfield.set(int num_vertices, int num_instances, int first_vertex, int first_instance) Initializes this struct with the specified values.Copies the specified struct data to this struct.intsizeof()Returnssizeof(struct).Methods inherited from class org.lwjgl.system.Pointer.Default
address, equals, hashCode, toStringMethods inherited from interface org.lwjgl.system.NativeResource
close, free
-
Field Details
-
SIZEOF
public static final int SIZEOFThe struct size in bytes. -
ALIGNOF
public static final int ALIGNOFThe struct alignment in bytes. -
NUM_VERTICES
public static final int NUM_VERTICESThe struct member offsets. -
NUM_INSTANCES
public static final int NUM_INSTANCESThe struct member offsets. -
FIRST_VERTEX
public static final int FIRST_VERTEXThe struct member offsets. -
FIRST_INSTANCE
public static final int FIRST_INSTANCEThe struct member offsets.
-
-
Constructor Details
-
SDL_GPUIndirectDrawCommand
Creates aSDL_GPUIndirectDrawCommandinstance 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 Details
-
sizeof
public int sizeof()Description copied from class:StructReturnssizeof(struct).- Specified by:
sizeofin classStruct<SDL_GPUIndirectDrawCommand>
-
num_vertices
public int num_vertices()- Returns:
- the value of the
num_verticesfield.
-
num_instances
public int num_instances()- Returns:
- the value of the
num_instancesfield.
-
first_vertex
public int first_vertex()- Returns:
- the value of the
first_vertexfield.
-
first_instance
public int first_instance()- Returns:
- the value of the
first_instancefield.
-
num_vertices
Sets the specified value to thenum_verticesfield. -
num_instances
Sets the specified value to thenum_instancesfield. -
first_vertex
Sets the specified value to thefirst_vertexfield. -
first_instance
Sets the specified value to thefirst_instancefield. -
set
public SDL_GPUIndirectDrawCommand set(int num_vertices, int num_instances, int first_vertex, int first_instance) Initializes this struct with the specified values. -
set
Copies the specified struct data to this struct.- Parameters:
src- the source struct- Returns:
- this struct
-
malloc
Returns a newSDL_GPUIndirectDrawCommandinstance allocated withmemAlloc. The instance must be explicitly freed. -
calloc
Returns a newSDL_GPUIndirectDrawCommandinstance allocated withmemCalloc. The instance must be explicitly freed. -
create
Returns a newSDL_GPUIndirectDrawCommandinstance allocated withBufferUtils. -
create
Returns a newSDL_GPUIndirectDrawCommandinstance for the specified memory address. -
createSafe
-
malloc
Returns a newSDL_GPUIndirectDrawCommand.Bufferinstance allocated withmemAlloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
calloc
Returns a newSDL_GPUIndirectDrawCommand.Bufferinstance allocated withmemCalloc. The instance must be explicitly freed.- Parameters:
capacity- the buffer capacity
-
create
Returns a newSDL_GPUIndirectDrawCommand.Bufferinstance allocated withBufferUtils.- Parameters:
capacity- the buffer capacity
-
create
Create aSDL_GPUIndirectDrawCommand.Bufferinstance at the specified memory.- Parameters:
address- the memory addresscapacity- the buffer capacity
-
createSafe
-
malloc
Returns a newSDL_GPUIndirectDrawCommandinstance allocated on the specifiedMemoryStack.- Parameters:
stack- the stack from which to allocate
-
calloc
Returns a newSDL_GPUIndirectDrawCommandinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
stack- the stack from which to allocate
-
malloc
Returns a newSDL_GPUIndirectDrawCommand.Bufferinstance allocated on the specifiedMemoryStack.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
calloc
Returns a newSDL_GPUIndirectDrawCommand.Bufferinstance allocated on the specifiedMemoryStackand initializes all its bits to zero.- Parameters:
capacity- the buffer capacitystack- the stack from which to allocate
-
nnum_vertices
public static int nnum_vertices(long struct) Unsafe version ofnum_vertices(). -
nnum_instances
public static int nnum_instances(long struct) Unsafe version ofnum_instances(). -
nfirst_vertex
public static int nfirst_vertex(long struct) Unsafe version offirst_vertex(). -
nfirst_instance
public static int nfirst_instance(long struct) Unsafe version offirst_instance(). -
nnum_vertices
public static void nnum_vertices(long struct, int value) Unsafe version ofnum_vertices. -
nnum_instances
public static void nnum_instances(long struct, int value) Unsafe version ofnum_instances. -
nfirst_vertex
public static void nfirst_vertex(long struct, int value) Unsafe version offirst_vertex. -
nfirst_instance
public static void nfirst_instance(long struct, int value) Unsafe version offirst_instance.
-