If MEMORY_ALLOCATE_DEVICE_MASK_BIT is not set, the number of instances allocated depends on whether MEMORY_HEAP_MULTI_INSTANCE_BIT is set in the memory heap. If MEMORY_HEAP_MULTI_INSTANCE_BIT is set, then memory is allocated for every physical device in the logical device (as if deviceMask has bits set for all device indices). If MEMORY_HEAP_MULTI_INSTANCE_BIT is not set, then a single instance of memory is allocated (as if deviceMask is set to one).
On some implementations, allocations from a multi-instance heap may consume memory on all physical devices even if the deviceMask excludes some devices. If VkPhysicalDeviceGroupProperties::subsetAllocation is TRUE, then memory is only consumed for the devices in the device mask.
In practice, most allocations on a multi-instance heap will be allocated across all physical devices. Unicast allocation support is an optional optimization for a minority of allocations.
MEMORY_ALLOCATE_DEVICE_MASK_BIT is set, deviceMask must be a valid device maskMEMORY_ALLOCATE_DEVICE_MASK_BIT is set, deviceMask must not be zerosType must be STRUCTURE_TYPE_MEMORY_ALLOCATE_FLAGS_INFOflags must be a valid combination of VkMemoryAllocateFlagBits values
struct VkMemoryAllocateFlagsInfo {
VkStructureType sType;
void const * pNext;
VkMemoryAllocateFlags flags;
uint32_t deviceMask;
}
| Modifier and Type | Class and Description |
|---|---|
| public static class | VkMemoryAllocateFlagsInfo.
An array of |
| Modifier and Type | Field and Description |
|---|---|
| public static final int | ALIGNOF
The struct alignment in bytes. |
| public static final int | DEVICEMASK
The struct member offsets. |
| public static final int | FLAGS
The struct member offsets. |
| public static final int | PNEXT
The struct member offsets. |
| public static final int | SIZEOF
The struct size in bytes. |
| public static final int | STYPE
The struct member offsets. |
| Access | Constructor and Description |
|---|---|
| protected | |
| public | VkMemoryAllocateFlagsInfo(ByteBuffer container)
Creates a |
| Modifier and Type | Method and Description |
|---|---|
| public static VkMemoryAllocateFlagsInfo | |
| public static VkMemoryAllocateFlagsInfo. | calloc(int
the buffer capacity capacity)Returns a new |
| public static VkMemoryAllocateFlagsInfo | calloc(MemoryStack
the stack from which to allocate stack)Returns a new |
| public static VkMemoryAllocateFlagsInfo. | calloc(int
the buffer capacity capacity, MemoryStack the stack from which to allocate stack)Returns a new |
| public static VkMemoryAllocateFlagsInfo | |
| public static VkMemoryAllocateFlagsInfo | |
| public static VkMemoryAllocateFlagsInfo. | |
| public static VkMemoryAllocateFlagsInfo. | |
| protected VkMemoryAllocateFlagsInfo | create(long
the struct memory address address, ByteBuffer an optional container buffer, to be referenced strongly by the struct instance. container)Implements abstract org. the constructor, but returns the exact type of the Struct subclass.
|
| public static VkMemoryAllocateFlagsInfo | |
| public static VkMemoryAllocateFlagsInfo | create(long address)
Returns a new |
| public static VkMemoryAllocateFlagsInfo. | create(int
the buffer capacity capacity)Returns a new |
| public static VkMemoryAllocateFlagsInfo. | create(long
the memory address address, int the buffer capacity capacity)Create a |
| public static VkMemoryAllocateFlagsInfo | |
| public static VkMemoryAllocateFlagsInfo. | |
| public int | deviceMask()
a mask of physical devices in the logical device, indicating that memory must be allocated on each device in the mask, if |
| public VkMemoryAllocateFlagsInfo | |
| public int | |
| public VkMemoryAllocateFlagsInfo | |
| public static VkMemoryAllocateFlagsInfo | |
| public static VkMemoryAllocateFlagsInfo. | malloc(int
the buffer capacity capacity)Returns a new |
| public static VkMemoryAllocateFlagsInfo | malloc(MemoryStack
the stack from which to allocate stack)Returns a new |
| public static VkMemoryAllocateFlagsInfo. | malloc(int
the buffer capacity capacity, MemoryStack the stack from which to allocate stack)Returns a new |
| public static VkMemoryAllocateFlagsInfo | |
| public static VkMemoryAllocateFlagsInfo | |
| public static VkMemoryAllocateFlagsInfo. | |
| public static VkMemoryAllocateFlagsInfo. | |
| public static int | |
| public static void | |
| public static int | |
| public static void | |
| public static long | |
| public static void | |
| public static int | |
| public static void | |
| public long | |
| public VkMemoryAllocateFlagsInfo | |
| public VkMemoryAllocateFlagsInfo | set(int sType, long pNext, int flags, int deviceMask)
Initializes this struct with the specified values. |
| public VkMemoryAllocateFlagsInfo | Returns: this structthe source struct src)Copies the specified struct data to this struct. |
| public int | |
| public int | |
| public VkMemoryAllocateFlagsInfo | |
| public VkMemoryAllocateFlagsInfo |
| ALIGNOF | back to summary |
|---|---|
| public static final int ALIGNOF The struct alignment in bytes. | |
| DEVICEMASK | back to summary |
|---|---|
| public static final int DEVICEMASK The struct member offsets. | |
| FLAGS | back to summary |
|---|---|
| public static final int FLAGS The struct member offsets. | |
| PNEXT | back to summary |
|---|---|
| public static final int PNEXT The struct member offsets. | |
| SIZEOF | back to summary |
|---|---|
| public static final int SIZEOF The struct size in bytes. | |
| STYPE | back to summary |
|---|---|
| public static final int STYPE The struct member offsets. | |
| VkMemoryAllocateFlagsInfo | back to summary |
|---|---|
| protected VkMemoryAllocateFlagsInfo(long address, ByteBuffer container) | |
| VkMemoryAllocateFlagsInfo | back to summary |
|---|---|
| public VkMemoryAllocateFlagsInfo(ByteBuffer container) Creates a The created instance holds a strong reference to the container object. | |
| calloc | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo calloc() Returns a new | |
| calloc | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo. Returns a new
| |
| calloc | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo calloc(MemoryStack stack) Returns a new
| |
| calloc | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo. Returns a new
| |
| callocStack | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo callocStack()
Deprecated
Deprecated for removal in 3.4.0. Use
| |
| callocStack | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo callocStack(MemoryStack stack)
Deprecated
Deprecated for removal in 3.4.0. Use
| |
| callocStack | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo. Deprecated
Deprecated for removal in 3.4.0. Use
| |
| callocStack | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo. Deprecated
Deprecated for removal in 3.4.0. Use
| |
| create | back to summary |
|---|---|
| protected VkMemoryAllocateFlagsInfo create(long address, ByteBuffer container) Implements abstract org. Doc from org. Similar to Effectively, every
| |
| create | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo create() Returns a new | |
| create | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo create(long address) Returns a new | |
| create | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo. Returns a new
| |
| create | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo. Create a
| |
| createSafe | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo createSafe(long address) Like
| |
| createSafe | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo. Like
| |
| deviceMask | back to summary |
|---|---|
| public int deviceMask() a mask of physical devices in the logical device, indicating that memory must be allocated on each device in the mask, if
| |
| deviceMask | back to summary |
|---|---|
| public VkMemoryAllocateFlagsInfo deviceMask(int value) Sets the specified value to the | |
| flags | back to summary |
|---|---|
| public int flags() a bitmask of
| |
| flags | back to summary |
|---|---|
| public VkMemoryAllocateFlagsInfo flags(int value) Sets the specified value to the | |
| malloc | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo malloc() Returns a new | |
| malloc | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo. Returns a new
| |
| malloc | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo malloc(MemoryStack stack) Returns a new
| |
| malloc | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo. Returns a new
| |
| mallocStack | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo mallocStack()
Deprecated
Deprecated for removal in 3.4.0. Use
| |
| mallocStack | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo mallocStack(MemoryStack stack)
Deprecated
Deprecated for removal in 3.4.0. Use
| |
| mallocStack | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo. Deprecated
Deprecated for removal in 3.4.0. Use
| |
| mallocStack | back to summary |
|---|---|
| public static VkMemoryAllocateFlagsInfo. Deprecated
Deprecated for removal in 3.4.0. Use
| |
| ndeviceMask | back to summary |
|---|---|
| public static int ndeviceMask(long struct) Unsafe version of | |
| ndeviceMask | back to summary |
|---|---|
| public static void ndeviceMask(long struct, int value) Unsafe version of | |
| nflags | back to summary |
|---|---|
| public static int nflags(long struct) Unsafe version of | |
| nflags | back to summary |
|---|---|
| public static void nflags(long struct, int value) Unsafe version of | |
| npNext | back to summary |
|---|---|
| public static long npNext(long struct) Unsafe version of | |
| npNext | back to summary |
|---|---|
| public static void npNext(long struct, long value) Unsafe version of | |
| nsType | back to summary |
|---|---|
| public static int nsType(long struct) Unsafe version of | |
| nsType | back to summary |
|---|---|
| public static void nsType(long struct, int value) Unsafe version of | |
| pNext | back to summary |
|---|---|
| public long pNext()
| |
| pNext | back to summary |
|---|---|
| public VkMemoryAllocateFlagsInfo pNext(long value) Sets the specified value to the | |
| set | back to summary |
|---|---|
| public VkMemoryAllocateFlagsInfo set(int sType, long pNext, int flags, int deviceMask) Initializes this struct with the specified values. | |
| set | back to summary |
|---|---|
| public VkMemoryAllocateFlagsInfo set(VkMemoryAllocateFlagsInfo src) Copies the specified struct data to this struct.
| |
| sizeof | back to summary |
|---|---|
| public int sizeof() Implements abstract org. Doc from org. Returns
| |
| sType | back to summary |
|---|---|
| public int sType() a
| |
| sType | back to summary |
|---|---|
| public VkMemoryAllocateFlagsInfo sType(int value) Sets the specified value to the | |
| sType$Default | back to summary |
|---|---|
| public VkMemoryAllocateFlagsInfo sType$Default() Sets the | |
VkMemoryAllocateFlagsInfo structs.
| Modifier and Type | Field and Description |
|---|---|
| private static final VkMemoryAllocateFlagsInfo |
| Access | Constructor and Description |
|---|---|
| public | Buffer(ByteBuffer container)
Creates a new |
| public | |
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| public int | |
| public VkMemoryAllocateFlagsInfo. | |
| public int | |
| public VkMemoryAllocateFlagsInfo. | |
| protected VkMemoryAllocateFlagsInfo | |
| public long | |
| public VkMemoryAllocateFlagsInfo. | |
| protected VkMemoryAllocateFlagsInfo. | |
| public int | |
| public VkMemoryAllocateFlagsInfo. | |
| public VkMemoryAllocateFlagsInfo. | sType$Default()
Sets the |
| ELEMENT_FACTORY | back to summary |
|---|---|
| private static final VkMemoryAllocateFlagsInfo ELEMENT_FACTORY | |
| Buffer | back to summary |
|---|---|
| public Buffer(ByteBuffer container) Creates a new 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 The created buffer instance holds a strong reference to the container object. | |
| Buffer | back to summary |
|---|---|
| public Buffer(long address, int cap) | |
| Buffer | back to summary |
|---|---|
| pack-priv Buffer(long address, ByteBuffer container, int mark, int pos, int lim, int cap) | |
| deviceMask | back to summary |
|---|---|
public int deviceMask()
| |
| deviceMask | back to summary |
|---|---|
| public VkMemoryAllocateFlagsInfo. Sets the specified value to the | |
| flags | back to summary |
|---|---|
public int flags()
| |
| flags | back to summary |
|---|---|
| public VkMemoryAllocateFlagsInfo. Sets the specified value to the | |
| getElementFactory | back to summary |
|---|---|
| protected VkMemoryAllocateFlagsInfo getElementFactory() Implements abstract org.
| |
| pNext | back to summary |
|---|---|
public long pNext()
| |
| pNext | back to summary |
|---|---|
| public VkMemoryAllocateFlagsInfo. Sets the specified value to the | |
| self | back to summary |
|---|---|
| protected VkMemoryAllocateFlagsInfo. Implements abstract org.
| |
| sType | back to summary |
|---|---|
public int sType()
| |
| sType | back to summary |
|---|---|
| public VkMemoryAllocateFlagsInfo. Sets the specified value to the | |
| sType$Default | back to summary |
|---|---|
| public VkMemoryAllocateFlagsInfo. Sets the | |