Class VmaAllocationInfo2
java.lang.Object
overrungl.struct.GroupType
overrungl.vma.VmaAllocationInfo2
- All Implemented Interfaces:
Addressable
- Direct Known Subclasses:
VmaAllocationInfo2.Buffer
Layout
struct VmaAllocationInfo2 {
(struct VmaAllocationInfo) VmaAllocationInfo allocationInfo;
(uint64_t) VkDeviceSize blockSize;
(uint32_t) VkBool32 dedicatedMemory;
};
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final GroupLayout
The struct layout ofVmaAllocationInfo2
.static final MemoryLayout
The memory layout ofallocationInfo
.static final MemoryLayout
The memory layout ofblockSize
.static final MemoryLayout
The memory layout ofdedicatedMemory
.static final long
The byte offset ofallocationInfo
.static final long
The byte offset ofblockSize
.static final long
The byte offset ofdedicatedMemory
.static final VarHandle
static final VarHandle
TheVarHandle
ofdedicatedMemory
of type(MemorySegment base, long baseOffset, long index)MemorySegment
. -
Constructor Summary
ConstructorsConstructorDescriptionVmaAllocationInfo2
(MemorySegment segment) CreatesVmaAllocationInfo2
with the given segment. -
Method Summary
Modifier and TypeMethodDescriptionstatic VmaAllocationInfo2
alloc
(SegmentAllocator allocator) Allocates aVmaAllocationInfo2
with the given segment allocator.static VmaAllocationInfo2.Buffer
alloc
(SegmentAllocator allocator, long count) Allocates aVmaAllocationInfo2
with the given segment allocator and count.ReturnsallocationInfo
.allocationInfo
(MemorySegment value) SetsallocationInfo
with the given value.static MemorySegment
allocationInfo
(MemorySegment segment, long index) ReturnsallocationInfo
at the given index.static void
allocationInfo
(MemorySegment segment, long index, MemorySegment value) SetsallocationInfo
with the given value at the given index.static VmaAllocationInfo2
allocInit
(SegmentAllocator allocator, MemorySegment allocationInfo) Allocates aVmaAllocationInfo2
with the given segment allocator and arguments like initializer list.static VmaAllocationInfo2
allocInit
(SegmentAllocator allocator, MemorySegment allocationInfo, long blockSize) Allocates aVmaAllocationInfo2
with the given segment allocator and arguments like initializer list.static VmaAllocationInfo2
allocInit
(SegmentAllocator allocator, MemorySegment allocationInfo, long blockSize, int dedicatedMemory) Allocates aVmaAllocationInfo2
with the given segment allocator and arguments like initializer list.asBuffer()
Converts this instance to a buffer.long
ReturnsblockSize
.blockSize
(long value) SetsblockSize
with the given value.static long
blockSize
(MemorySegment segment, long index) ReturnsblockSize
at the given index.static void
blockSize
(MemorySegment segment, long index, long value) SetsblockSize
with the given value at the given index.Copies from the given source.int
ReturnsdedicatedMemory
.dedicatedMemory
(int value) SetsdedicatedMemory
with the given value.static int
dedicatedMemory
(MemorySegment segment, long index) ReturnsdedicatedMemory
at the given index.static void
dedicatedMemory
(MemorySegment segment, long index, int value) SetsdedicatedMemory
with the given value at the given index.static VmaAllocationInfo2.Buffer
of
(MemorySegment segment) CreatesVmaAllocationInfo2
with the given segment.static VmaAllocationInfo2
ofNative
(MemorySegment segment) CreatesVmaAllocationInfo2
with the given segment.static VmaAllocationInfo2.Buffer
ofNative
(MemorySegment segment, long count) CreatesVmaAllocationInfo2
with the given segment.Methods inherited from class overrungl.struct.GroupType
estimateCount, estimateCount, groupLayout, segment
-
Field Details
-
LAYOUT
The struct layout ofVmaAllocationInfo2
. -
OFFSET_allocationInfo
public static final long OFFSET_allocationInfoThe byte offset ofallocationInfo
. -
LAYOUT_allocationInfo
The memory layout ofallocationInfo
. -
OFFSET_blockSize
public static final long OFFSET_blockSizeThe byte offset ofblockSize
. -
LAYOUT_blockSize
The memory layout ofblockSize
. -
VH_blockSize
-
OFFSET_dedicatedMemory
public static final long OFFSET_dedicatedMemoryThe byte offset ofdedicatedMemory
. -
LAYOUT_dedicatedMemory
The memory layout ofdedicatedMemory
. -
VH_dedicatedMemory
-
-
Constructor Details
-
VmaAllocationInfo2
CreatesVmaAllocationInfo2
with the given segment.- Parameters:
segment
- the memory segment
-
-
Method Details
-
of
CreatesVmaAllocationInfo2
with the given segment.- Parameters:
segment
- the memory segment- Returns:
- the created instance or
null
if the segment isNULL
-
ofNative
Creates
VmaAllocationInfo2
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
VmaAllocationInfo2
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 aVmaAllocationInfo2
with the given segment allocator.- Parameters:
allocator
- the segment allocator- Returns:
- the allocated
VmaAllocationInfo2
-
alloc
Allocates aVmaAllocationInfo2
with the given segment allocator and count.- Parameters:
allocator
- the segment allocatorcount
- the count- Returns:
- the allocated
VmaAllocationInfo2
-
allocInit
public static VmaAllocationInfo2 allocInit(SegmentAllocator allocator, MemorySegment allocationInfo, long blockSize, int dedicatedMemory) Allocates aVmaAllocationInfo2
with the given segment allocator and arguments like initializer list.- Parameters:
allocator
- the segment allocatorallocationInfo
-allocationInfo
blockSize
-blockSize
dedicatedMemory
-dedicatedMemory
- Returns:
- the allocated
VmaAllocationInfo2
-
allocInit
public static VmaAllocationInfo2 allocInit(SegmentAllocator allocator, MemorySegment allocationInfo, long blockSize) Allocates aVmaAllocationInfo2
with the given segment allocator and arguments like initializer list.- Parameters:
allocator
- the segment allocatorallocationInfo
-allocationInfo
blockSize
-blockSize
- Returns:
- the allocated
VmaAllocationInfo2
-
allocInit
public static VmaAllocationInfo2 allocInit(SegmentAllocator allocator, MemorySegment allocationInfo) Allocates aVmaAllocationInfo2
with the given segment allocator and arguments like initializer list.- Parameters:
allocator
- the segment allocatorallocationInfo
-allocationInfo
- Returns:
- the allocated
VmaAllocationInfo2
-
copyFrom
Copies from the given source.- Parameters:
src
- the source- Returns:
this
-
asBuffer
-
allocationInfo
ReturnsallocationInfo
at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffer- Returns:
allocationInfo
at the given index
-
allocationInfo
-
allocationInfo
SetsallocationInfo
with the given value at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffervalue
- the value
-
allocationInfo
SetsallocationInfo
with the given value.- Parameters:
value
- the value- Returns:
this
-
blockSize
ReturnsblockSize
at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffer- Returns:
blockSize
at the given index
-
blockSize
public long blockSize()ReturnsblockSize
.- Returns:
blockSize
-
blockSize
SetsblockSize
with the given value at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffervalue
- the value
-
blockSize
SetsblockSize
with the given value.- Parameters:
value
- the value- Returns:
this
-
dedicatedMemory
ReturnsdedicatedMemory
at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffer- Returns:
dedicatedMemory
at the given index
-
dedicatedMemory
public int dedicatedMemory()ReturnsdedicatedMemory
.- Returns:
dedicatedMemory
-
dedicatedMemory
SetsdedicatedMemory
with the given value at the given index.- Parameters:
segment
- the segment of the structindex
- the index of the struct buffervalue
- the value
-
dedicatedMemory
SetsdedicatedMemory
with the given value.- Parameters:
value
- the value- Returns:
this
-