public class VkBindImageMemoryDeviceGroupInfo
extends org.lwjgl.system.Struct
implements org.lwjgl.system.NativeResource
The VkBindImageMemoryDeviceGroupInfo structure is defined as:
sType is the type of this structure.pNext is NULL or a pointer to an extension-specific structure.deviceIndexCount is the number of elements in pDeviceIndices.pDeviceIndices is a pointer to an array of device indices.splitInstanceBindRegionCount is the number of elements in pSplitInstanceBindRegions.pSplitInstanceBindRegions is a pointer to an array of VkRect2D structures describing which regions of the image are attached to each instance of memory.If deviceIndexCount is greater than zero, then on device index i image is attached to the instance of the memory on the physical device with device index pDeviceIndices[i].
Let N be the number of physical devices in the logical device. If splitInstanceBindRegionCount is greater than zero, then pSplitInstanceBindRegions is an array of N2 rectangles, where the image region specified by the rectangle at element i*N+j in resource instance i is bound to the memory instance j. The blocks of the memory that are bound to each sparse image block region use an offset in memory, relative to memoryOffset, computed as if the whole image were being bound to a contiguous range of memory. In other words, horizontally adjacent image blocks use consecutive blocks of memory, vertically adjacent image blocks are separated by the number of bytes per block multiplied by the width in blocks of image, and the block at (0,0) corresponds to memory starting at memoryOffset.
If splitInstanceBindRegionCount and deviceIndexCount are zero and the memory comes from a memory heap with the MEMORY_HEAP_MULTI_INSTANCE_BIT bit set, then it is as if pDeviceIndices contains consecutive indices from zero to the number of physical devices in the logical device, minus one. In other words, by default each physical device attaches to its own instance of the memory.
If splitInstanceBindRegionCount and deviceIndexCount are zero and the memory comes from a memory heap without the MEMORY_HEAP_MULTI_INSTANCE_BIT bit set, then it is as if pDeviceIndices contains an array of zeros. In other words, by default each physical device attaches to instance zero.
deviceIndexCount and splitInstanceBindRegionCount must be zero.deviceIndexCount must either be zero or equal to the number of physical devices in the logical devicepDeviceIndices must be valid device indices.splitInstanceBindRegionCount must either be zero or equal to the number of physical devices in the logical device squaredpSplitInstanceBindRegions that correspond to the same instance of an image must not overlap.offset.x member of any element of pSplitInstanceBindRegions must be a multiple of the sparse image block width (VkSparseImageFormatProperties::imageGranularity.width) of all non-metadata aspects of the imageoffset.y member of any element of pSplitInstanceBindRegions must be a multiple of the sparse image block height (VkSparseImageFormatProperties::imageGranularity.height) of all non-metadata aspects of the imageextent.width member of any element of pSplitInstanceBindRegions must either be a multiple of the sparse image block width of all non-metadata aspects of the image, or else extent.width + offset.x must equal the width of the image subresourceextent.height member of any element of pSplitInstanceBindRegions must either be a multiple of the sparse image block height of all non-metadata aspects of the image, or else extent.height + offset.y must equal the width of the image subresourcesType must be STRUCTURE_TYPE_BIND_IMAGE_MEMORY_DEVICE_GROUP_INFOdeviceIndexCount is not 0, pDeviceIndices must be a valid pointer to an array of deviceIndexCount uint32_t valuessplitInstanceBindRegionCount is not 0, pSplitInstanceBindRegions must be a valid pointer to an array of splitInstanceBindRegionCount VkRect2D structures
struct VkBindImageMemoryDeviceGroupInfo {
VkStructureType sType;
void const * pNext;
uint32_t deviceIndexCount;
uint32_t const * pDeviceIndices;
uint32_t splitInstanceBindRegionCount;
VkRect2D const * pSplitInstanceBindRegions;
}| Modifier and Type | Class and Description |
|---|---|
static class |
VkBindImageMemoryDeviceGroupInfo.Buffer
An array of
VkBindImageMemoryDeviceGroupInfo structs. |
| Modifier and Type | Field and Description |
|---|---|
static int |
ALIGNOF
The struct alignment in bytes.
|
static int |
DEVICEINDEXCOUNT
The struct member offsets.
|
static int |
PDEVICEINDICES
The struct member offsets.
|
static int |
PNEXT
The struct member offsets.
|
static int |
PSPLITINSTANCEBINDREGIONS
The struct member offsets.
|
static int |
SIZEOF
The struct size in bytes.
|
static int |
SPLITINSTANCEBINDREGIONCOUNT
The struct member offsets.
|
static int |
STYPE
The struct member offsets.
|
| Constructor and Description |
|---|
VkBindImageMemoryDeviceGroupInfo(java.nio.ByteBuffer container)
Creates a
VkBindImageMemoryDeviceGroupInfo instance at the current position of the specified ByteBuffer container. |
| Modifier and Type | Method and Description |
|---|---|
static VkBindImageMemoryDeviceGroupInfo |
calloc()
Returns a new
VkBindImageMemoryDeviceGroupInfo instance allocated with memCalloc. |
static VkBindImageMemoryDeviceGroupInfo.Buffer |
calloc(int capacity)
Returns a new
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated with memCalloc. |
static VkBindImageMemoryDeviceGroupInfo |
callocStack()
Returns a new
VkBindImageMemoryDeviceGroupInfo instance allocated on the thread-local MemoryStack and initializes all its bits to zero. |
static VkBindImageMemoryDeviceGroupInfo.Buffer |
callocStack(int capacity)
Returns a new
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated on the thread-local MemoryStack and initializes all its bits to zero. |
static VkBindImageMemoryDeviceGroupInfo.Buffer |
callocStack(int capacity,
org.lwjgl.system.MemoryStack stack)
Returns a new
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero. |
static VkBindImageMemoryDeviceGroupInfo |
callocStack(org.lwjgl.system.MemoryStack stack)
Returns a new
VkBindImageMemoryDeviceGroupInfo instance allocated on the specified MemoryStack and initializes all its bits to zero. |
static VkBindImageMemoryDeviceGroupInfo |
create()
Returns a new
VkBindImageMemoryDeviceGroupInfo instance allocated with BufferUtils. |
static VkBindImageMemoryDeviceGroupInfo.Buffer |
create(int capacity)
Returns a new
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated with BufferUtils. |
static VkBindImageMemoryDeviceGroupInfo |
create(long address)
Returns a new
VkBindImageMemoryDeviceGroupInfo instance for the specified memory address. |
static VkBindImageMemoryDeviceGroupInfo.Buffer |
create(long address,
int capacity)
Create a
VkBindImageMemoryDeviceGroupInfo.Buffer instance at the specified memory. |
static VkBindImageMemoryDeviceGroupInfo |
createSafe(long address)
|
static VkBindImageMemoryDeviceGroupInfo.Buffer |
createSafe(long address,
int capacity)
|
int |
deviceIndexCount()
Returns the value of the
deviceIndexCount field. |
static VkBindImageMemoryDeviceGroupInfo |
malloc()
Returns a new
VkBindImageMemoryDeviceGroupInfo instance allocated with memAlloc. |
static VkBindImageMemoryDeviceGroupInfo.Buffer |
malloc(int capacity)
Returns a new
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated with memAlloc. |
static VkBindImageMemoryDeviceGroupInfo |
mallocStack()
Returns a new
VkBindImageMemoryDeviceGroupInfo instance allocated on the thread-local MemoryStack. |
static VkBindImageMemoryDeviceGroupInfo.Buffer |
mallocStack(int capacity)
Returns a new
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated on the thread-local MemoryStack. |
static VkBindImageMemoryDeviceGroupInfo.Buffer |
mallocStack(int capacity,
org.lwjgl.system.MemoryStack stack)
Returns a new
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated on the specified MemoryStack. |
static VkBindImageMemoryDeviceGroupInfo |
mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a new
VkBindImageMemoryDeviceGroupInfo instance allocated on the specified MemoryStack. |
static int |
ndeviceIndexCount(long struct)
Unsafe version of
deviceIndexCount(). |
static void |
ndeviceIndexCount(long struct,
int value)
Sets the specified value to the
deviceIndexCount field of the specified struct. |
static java.nio.IntBuffer |
npDeviceIndices(long struct)
Unsafe version of
pDeviceIndices. |
static void |
npDeviceIndices(long struct,
java.nio.IntBuffer value)
Unsafe version of
pDeviceIndices. |
static long |
npNext(long struct)
Unsafe version of
pNext(). |
static void |
npNext(long struct,
long value)
Unsafe version of
pNext. |
static VkRect2D.Buffer |
npSplitInstanceBindRegions(long struct)
Unsafe version of
pSplitInstanceBindRegions(). |
static void |
npSplitInstanceBindRegions(long struct,
VkRect2D.Buffer value)
Unsafe version of
pSplitInstanceBindRegions. |
static int |
nsplitInstanceBindRegionCount(long struct)
Unsafe version of
splitInstanceBindRegionCount(). |
static void |
nsplitInstanceBindRegionCount(long struct,
int value)
Sets the specified value to the
splitInstanceBindRegionCount field of the specified struct. |
static int |
nsType(long struct)
Unsafe version of
sType(). |
static void |
nsType(long struct,
int value)
Unsafe version of
sType. |
java.nio.IntBuffer |
pDeviceIndices()
Returns a
IntBuffer view of the data pointed to by the pDeviceIndices field. |
VkBindImageMemoryDeviceGroupInfo |
pDeviceIndices(java.nio.IntBuffer value)
Sets the address of the specified
IntBuffer to the pDeviceIndices field. |
long |
pNext()
Returns the value of the
pNext field. |
VkBindImageMemoryDeviceGroupInfo |
pNext(long value)
Sets the specified value to the
pNext field. |
VkRect2D.Buffer |
pSplitInstanceBindRegions()
Returns a
VkRect2D.Buffer view of the struct array pointed to by the pSplitInstanceBindRegions field. |
VkBindImageMemoryDeviceGroupInfo |
pSplitInstanceBindRegions(VkRect2D.Buffer value)
Sets the address of the specified
VkRect2D.Buffer to the pSplitInstanceBindRegions field. |
VkBindImageMemoryDeviceGroupInfo |
set(int sType,
long pNext,
java.nio.IntBuffer pDeviceIndices,
VkRect2D.Buffer pSplitInstanceBindRegions)
Initializes this struct with the specified values.
|
VkBindImageMemoryDeviceGroupInfo |
set(VkBindImageMemoryDeviceGroupInfo src)
Copies the specified struct data to this struct.
|
int |
sizeof() |
int |
splitInstanceBindRegionCount()
Returns the value of the
splitInstanceBindRegionCount field. |
int |
sType()
Returns the value of the
sType field. |
VkBindImageMemoryDeviceGroupInfo |
sType(int value)
Sets the specified value to the
sType field. |
static void |
validate(long struct)
Validates pointer members that should not be
NULL. |
static void |
validate(long array,
int count)
Calls
validate(long) for each struct contained in the specified struct array. |
public static final int SIZEOF
public static final int ALIGNOF
public static final int STYPE
public static final int PNEXT
public static final int DEVICEINDEXCOUNT
public static final int PDEVICEINDICES
public static final int SPLITINSTANCEBINDREGIONCOUNT
public static final int PSPLITINSTANCEBINDREGIONS
public VkBindImageMemoryDeviceGroupInfo(java.nio.ByteBuffer container)
VkBindImageMemoryDeviceGroupInfo instance at the current position of the specified ByteBuffer container. 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.
public int sizeof()
sizeof in class org.lwjgl.system.Structpublic int sType()
sType field.public long pNext()
pNext field.public int deviceIndexCount()
deviceIndexCount field.@Nullable public java.nio.IntBuffer pDeviceIndices()
IntBuffer view of the data pointed to by the pDeviceIndices field.public int splitInstanceBindRegionCount()
splitInstanceBindRegionCount field.@Nullable public VkRect2D.Buffer pSplitInstanceBindRegions()
VkRect2D.Buffer view of the struct array pointed to by the pSplitInstanceBindRegions field.public VkBindImageMemoryDeviceGroupInfo sType(int value)
sType field.public VkBindImageMemoryDeviceGroupInfo pNext(long value)
pNext field.public VkBindImageMemoryDeviceGroupInfo pDeviceIndices(@Nullable java.nio.IntBuffer value)
IntBuffer to the pDeviceIndices field.public VkBindImageMemoryDeviceGroupInfo pSplitInstanceBindRegions(@Nullable VkRect2D.Buffer value)
VkRect2D.Buffer to the pSplitInstanceBindRegions field.public VkBindImageMemoryDeviceGroupInfo set(int sType, long pNext, @Nullable java.nio.IntBuffer pDeviceIndices, @Nullable VkRect2D.Buffer pSplitInstanceBindRegions)
public VkBindImageMemoryDeviceGroupInfo set(VkBindImageMemoryDeviceGroupInfo src)
src - the source structpublic static VkBindImageMemoryDeviceGroupInfo malloc()
VkBindImageMemoryDeviceGroupInfo instance allocated with memAlloc. The instance must be explicitly freed.public static VkBindImageMemoryDeviceGroupInfo calloc()
VkBindImageMemoryDeviceGroupInfo instance allocated with memCalloc. The instance must be explicitly freed.public static VkBindImageMemoryDeviceGroupInfo create()
VkBindImageMemoryDeviceGroupInfo instance allocated with BufferUtils.public static VkBindImageMemoryDeviceGroupInfo create(long address)
VkBindImageMemoryDeviceGroupInfo instance for the specified memory address.@Nullable public static VkBindImageMemoryDeviceGroupInfo createSafe(long address)
public static VkBindImageMemoryDeviceGroupInfo.Buffer malloc(int capacity)
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated with memAlloc. The instance must be explicitly freed.capacity - the buffer capacitypublic static VkBindImageMemoryDeviceGroupInfo.Buffer calloc(int capacity)
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated with memCalloc. The instance must be explicitly freed.capacity - the buffer capacitypublic static VkBindImageMemoryDeviceGroupInfo.Buffer create(int capacity)
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated with BufferUtils.capacity - the buffer capacitypublic static VkBindImageMemoryDeviceGroupInfo.Buffer create(long address, int capacity)
VkBindImageMemoryDeviceGroupInfo.Buffer instance at the specified memory.address - the memory addresscapacity - the buffer capacity@Nullable public static VkBindImageMemoryDeviceGroupInfo.Buffer createSafe(long address, int capacity)
public static VkBindImageMemoryDeviceGroupInfo mallocStack()
VkBindImageMemoryDeviceGroupInfo instance allocated on the thread-local MemoryStack.public static VkBindImageMemoryDeviceGroupInfo callocStack()
VkBindImageMemoryDeviceGroupInfo instance allocated on the thread-local MemoryStack and initializes all its bits to zero.public static VkBindImageMemoryDeviceGroupInfo mallocStack(org.lwjgl.system.MemoryStack stack)
VkBindImageMemoryDeviceGroupInfo instance allocated on the specified MemoryStack.stack - the stack from which to allocatepublic static VkBindImageMemoryDeviceGroupInfo callocStack(org.lwjgl.system.MemoryStack stack)
VkBindImageMemoryDeviceGroupInfo instance allocated on the specified MemoryStack and initializes all its bits to zero.stack - the stack from which to allocatepublic static VkBindImageMemoryDeviceGroupInfo.Buffer mallocStack(int capacity)
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated on the thread-local MemoryStack.capacity - the buffer capacitypublic static VkBindImageMemoryDeviceGroupInfo.Buffer callocStack(int capacity)
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated on the thread-local MemoryStack and initializes all its bits to zero.capacity - the buffer capacitypublic static VkBindImageMemoryDeviceGroupInfo.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated on the specified MemoryStack.stack - the stack from which to allocatecapacity - the buffer capacitypublic static VkBindImageMemoryDeviceGroupInfo.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
VkBindImageMemoryDeviceGroupInfo.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.stack - the stack from which to allocatecapacity - the buffer capacitypublic static int nsType(long struct)
sType().public static long npNext(long struct)
pNext().public static int ndeviceIndexCount(long struct)
deviceIndexCount().@Nullable public static java.nio.IntBuffer npDeviceIndices(long struct)
pDeviceIndices.public static int nsplitInstanceBindRegionCount(long struct)
splitInstanceBindRegionCount().@Nullable public static VkRect2D.Buffer npSplitInstanceBindRegions(long struct)
pSplitInstanceBindRegions().public static void nsType(long struct,
int value)
sType.public static void npNext(long struct,
long value)
pNext.public static void ndeviceIndexCount(long struct,
int value)
deviceIndexCount field of the specified struct.public static void npDeviceIndices(long struct,
@Nullable
java.nio.IntBuffer value)
pDeviceIndices.public static void nsplitInstanceBindRegionCount(long struct,
int value)
splitInstanceBindRegionCount field of the specified struct.public static void npSplitInstanceBindRegions(long struct,
@Nullable
VkRect2D.Buffer value)
pSplitInstanceBindRegions.public static void validate(long struct)
NULL.struct - the struct to validatepublic static void validate(long array,
int count)
validate(long) for each struct contained in the specified struct array.array - the struct array to validatecount - the number of structs in arrayCopyright LWJGL. All Rights Reserved. License terms.