Class VkDrawIndirectCommand
java.lang.Object
overrungl.struct.GroupType
overrungl.vulkan.struct.VkDrawIndirectCommand
- All Implemented Interfaces:
Addressable
- Direct Known Subclasses:
VkDrawIndirectCommand.Buffer
Layout
struct VkDrawIndirectCommand {
uint32_t vertexCount;
uint32_t instanceCount;
uint32_t firstVertex;
uint32_t firstInstance;
};
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final GroupLayout
The struct layout ofVkDrawIndirectCommand
.static final MemoryLayout
The memory layout offirstInstance
.static final MemoryLayout
The memory layout offirstVertex
.static final MemoryLayout
The memory layout ofinstanceCount
.static final MemoryLayout
The memory layout ofvertexCount
.static final long
The byte offset offirstInstance
.static final long
The byte offset offirstVertex
.static final long
The byte offset ofinstanceCount
.static final long
The byte offset ofvertexCount
.static final VarHandle
TheVarHandle
offirstInstance
of type(MemorySegment base, long baseOffset, long index)MemorySegment
.static final VarHandle
TheVarHandle
offirstVertex
of type(MemorySegment base, long baseOffset, long index)MemorySegment
.static final VarHandle
TheVarHandle
ofinstanceCount
of type(MemorySegment base, long baseOffset, long index)MemorySegment
.static final VarHandle
TheVarHandle
ofvertexCount
of type(MemorySegment base, long baseOffset, long index)MemorySegment
. -
Constructor Summary
ConstructorsConstructorDescriptionVkDrawIndirectCommand
(MemorySegment segment) CreatesVkDrawIndirectCommand
with the given segment. -
Method Summary
Modifier and TypeMethodDescriptionstatic VkDrawIndirectCommand
alloc
(SegmentAllocator allocator) Allocates aVkDrawIndirectCommand
with the given segment allocator.static VkDrawIndirectCommand.Buffer
alloc
(SegmentAllocator allocator, long count) Allocates aVkDrawIndirectCommand
with the given segment allocator and count.asBuffer()
Converts this instance to a buffer.Copies from the given source.int
ReturnsfirstInstance
.firstInstance
(int value) SetsfirstInstance
with the given value.static int
firstInstance
(MemorySegment segment, long index) ReturnsfirstInstance
at the given index.static void
firstInstance
(MemorySegment segment, long index, int value) SetsfirstInstance
with the given value at the given index.int
ReturnsfirstVertex
.firstVertex
(int value) SetsfirstVertex
with the given value.static int
firstVertex
(MemorySegment segment, long index) ReturnsfirstVertex
at the given index.static void
firstVertex
(MemorySegment segment, long index, int value) SetsfirstVertex
with the given value at the given index.int
ReturnsinstanceCount
.instanceCount
(int value) SetsinstanceCount
with the given value.static int
instanceCount
(MemorySegment segment, long index) ReturnsinstanceCount
at the given index.static void
instanceCount
(MemorySegment segment, long index, int value) SetsinstanceCount
with the given value at the given index.static VkDrawIndirectCommand.Buffer
of
(MemorySegment segment) CreatesVkDrawIndirectCommand
with the given segment.static VkDrawIndirectCommand
ofNative
(MemorySegment segment) CreatesVkDrawIndirectCommand
with the given segment.static VkDrawIndirectCommand.Buffer
ofNative
(MemorySegment segment, long count) CreatesVkDrawIndirectCommand
with the given segment.int
ReturnsvertexCount
.vertexCount
(int value) SetsvertexCount
with the given value.static int
vertexCount
(MemorySegment segment, long index) ReturnsvertexCount
at the given index.static void
vertexCount
(MemorySegment segment, long index, int value) SetsvertexCount
with the given value at the given index.Methods inherited from class overrungl.struct.GroupType
estimateCount, estimateCount, groupLayout, segment
-
Field Details
-
LAYOUT
The struct layout ofVkDrawIndirectCommand
. -
OFFSET_vertexCount
public static final long OFFSET_vertexCountThe byte offset ofvertexCount
. -
LAYOUT_vertexCount
The memory layout ofvertexCount
. -
VH_vertexCount
-
OFFSET_instanceCount
public static final long OFFSET_instanceCountThe byte offset ofinstanceCount
. -
LAYOUT_instanceCount
The memory layout ofinstanceCount
. -
VH_instanceCount
-
OFFSET_firstVertex
public static final long OFFSET_firstVertexThe byte offset offirstVertex
. -
LAYOUT_firstVertex
The memory layout offirstVertex
. -
VH_firstVertex
-
OFFSET_firstInstance
public static final long OFFSET_firstInstanceThe byte offset offirstInstance
. -
LAYOUT_firstInstance
The memory layout offirstInstance
. -
VH_firstInstance
-
-
Constructor Details
-
VkDrawIndirectCommand
CreatesVkDrawIndirectCommand
with the given segment.- Parameters:
segment
- the memory segment
-
-
Method Details
-
of
CreatesVkDrawIndirectCommand
with the given segment.- Parameters:
segment
- the memory segment- Returns:
- the created instance or
null
if the segment isNULL
-
ofNative
Creates
VkDrawIndirectCommand
with the given segment.Reinterprets the segment if zero-length.
- Parameters:
segment
- the memory segment- Returns:
- the created instance or
null
if the segment isNULL
-
ofNative
Creates
VkDrawIndirectCommand
with the given segment.Reinterprets the segment if zero-length.
- Parameters:
segment
- the memory segmentcount
- the count of the buffer- Returns:
- the created instance or
null
if the segment isNULL
-
alloc
Allocates aVkDrawIndirectCommand
with the given segment allocator.- Parameters:
allocator
- the segment allocator- Returns:
- the allocated
VkDrawIndirectCommand
-
alloc
Allocates aVkDrawIndirectCommand
with the given segment allocator and count.- Parameters:
allocator
- the segment allocatorcount
- the count- Returns:
- the allocated
VkDrawIndirectCommand
-
copyFrom
Copies from the given source.- Parameters:
src
- the source- Returns:
this
-
asBuffer
Converts this instance to a buffer.- Returns:
- the buffer
-
vertexCount
ReturnsvertexCount
at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffer- Returns:
vertexCount
at the given index
-
vertexCount
public int vertexCount()ReturnsvertexCount
.- Returns:
vertexCount
-
vertexCount
SetsvertexCount
with the given value at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffervalue
- the value
-
vertexCount
SetsvertexCount
with the given value.- Parameters:
value
- the value- Returns:
this
-
instanceCount
ReturnsinstanceCount
at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffer- Returns:
instanceCount
at the given index
-
instanceCount
public int instanceCount()ReturnsinstanceCount
.- Returns:
instanceCount
-
instanceCount
SetsinstanceCount
with the given value at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffervalue
- the value
-
instanceCount
SetsinstanceCount
with the given value.- Parameters:
value
- the value- Returns:
this
-
firstVertex
ReturnsfirstVertex
at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffer- Returns:
firstVertex
at the given index
-
firstVertex
public int firstVertex()ReturnsfirstVertex
.- Returns:
firstVertex
-
firstVertex
SetsfirstVertex
with the given value at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffervalue
- the value
-
firstVertex
SetsfirstVertex
with the given value.- Parameters:
value
- the value- Returns:
this
-
firstInstance
ReturnsfirstInstance
at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffer- Returns:
firstInstance
at the given index
-
firstInstance
public int firstInstance()ReturnsfirstInstance
.- Returns:
firstInstance
-
firstInstance
SetsfirstInstance
with the given value at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffervalue
- the value
-
firstInstance
SetsfirstInstance
with the given value.- Parameters:
value
- the value- Returns:
this
-