Package org.lwjgl.vulkan
Class VkPhysicalDeviceMemoryBudgetPropertiesEXT
- java.lang.Object
-
- org.lwjgl.system.Pointer.Default
-
- org.lwjgl.system.Struct
-
- org.lwjgl.vulkan.VkPhysicalDeviceMemoryBudgetPropertiesEXT
-
- All Implemented Interfaces:
java.lang.AutoCloseable
,org.lwjgl.system.NativeResource
,org.lwjgl.system.Pointer
public class VkPhysicalDeviceMemoryBudgetPropertiesEXT extends org.lwjgl.system.Struct implements org.lwjgl.system.NativeResource
Structure specifying physical device memory budget and usage.Description
The values returned in this structure are not invariant. The
heapBudget
andheapUsage
values must be zero for array elements greater than or equal toVkPhysicalDeviceMemoryProperties
::memoryHeapCount
. TheheapBudget
value must be non-zero for array elements less thanVkPhysicalDeviceMemoryProperties
::memoryHeapCount
. TheheapBudget
value must be less than or equal toVkMemoryHeap
::size
for each heap.Valid Usage (Implicit)
Member documentation
sType
– the type of this structure.pNext
–NULL
or a pointer to an extension-specific structure.heapBudget[VK_MAX_MEMORY_HEAPS]
– an array of memory budgets, with one element for each memory heap. A heap’s budget is a rough estimate of how much memory the process can allocate from that heap before allocations may fail or cause performance degradation. The budget includes any currently allocated device memory.heapUsage[VK_MAX_MEMORY_HEAPS]
– an array of memory usage, with one element for each memory heap. A heap’s usage is an estimate of how much memory the process is currently using in that heap.
Layout
struct VkPhysicalDeviceMemoryBudgetPropertiesEXT { VkStructureType sType; void * pNext; VkDeviceSize heapBudget[VK_MAX_MEMORY_HEAPS]; VkDeviceSize heapUsage[VK_MAX_MEMORY_HEAPS]; }
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
An array ofVkPhysicalDeviceMemoryBudgetPropertiesEXT
structs.
-
Constructor Summary
Constructors Constructor Description VkPhysicalDeviceMemoryBudgetPropertiesEXT(java.nio.ByteBuffer container)
Creates aVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance at the current position of the specifiedByteBuffer
container.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static VkPhysicalDeviceMemoryBudgetPropertiesEXT
calloc()
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated withmemCalloc
.static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
calloc(int capacity)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated withmemCalloc
.static VkPhysicalDeviceMemoryBudgetPropertiesEXT
callocStack()
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
callocStack(int capacity)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static VkPhysicalDeviceMemoryBudgetPropertiesEXT
callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.static VkPhysicalDeviceMemoryBudgetPropertiesEXT
create()
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated withBufferUtils
.static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
create(int capacity)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated withBufferUtils
.static VkPhysicalDeviceMemoryBudgetPropertiesEXT
create(long address)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance for the specified memory address.static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
create(long address, int capacity)
Create aVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance at the specified memory.static VkPhysicalDeviceMemoryBudgetPropertiesEXT
createSafe(long address)
static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
createSafe(long address, int capacity)
java.nio.LongBuffer
heapBudget()
Returns aLongBuffer
view of theheapBudget
field.long
heapBudget(int index)
Returns the value at the specified index of theheapBudget
field.java.nio.LongBuffer
heapUsage()
Returns aLongBuffer
view of theheapUsage
field.long
heapUsage(int index)
Returns the value at the specified index of theheapUsage
field.static VkPhysicalDeviceMemoryBudgetPropertiesEXT
malloc()
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated withmemAlloc
.static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
malloc(int capacity)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated withmemAlloc
.static VkPhysicalDeviceMemoryBudgetPropertiesEXT
mallocStack()
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated on the thread-localMemoryStack
.static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
mallocStack(int capacity)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated on the thread-localMemoryStack
.static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated on the specifiedMemoryStack
.static VkPhysicalDeviceMemoryBudgetPropertiesEXT
mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated on the specifiedMemoryStack
.static java.nio.LongBuffer
nheapBudget(long struct)
Unsafe version ofheapBudget()
.static long
nheapBudget(long struct, int index)
Unsafe version ofheapBudget
.static java.nio.LongBuffer
nheapUsage(long struct)
Unsafe version ofheapUsage()
.static long
nheapUsage(long struct, int index)
Unsafe version ofheapUsage
.static long
npNext(long struct)
Unsafe version ofpNext()
.static void
npNext(long struct, long value)
Unsafe version ofpNext
.static int
nsType(long struct)
Unsafe version ofsType()
.static void
nsType(long struct, int value)
Unsafe version ofsType
.long
pNext()
Returns the value of thepNext
field.VkPhysicalDeviceMemoryBudgetPropertiesEXT
pNext(long value)
Sets the specified value to thepNext
field.VkPhysicalDeviceMemoryBudgetPropertiesEXT
set(int sType, long pNext)
Initializes this struct with the specified values.VkPhysicalDeviceMemoryBudgetPropertiesEXT
set(VkPhysicalDeviceMemoryBudgetPropertiesEXT src)
Copies the specified struct data to this struct.int
sizeof()
int
sType()
Returns the value of thesType
field.VkPhysicalDeviceMemoryBudgetPropertiesEXT
sType(int value)
Sets the specified value to thesType
field.
-
-
-
Constructor Detail
-
VkPhysicalDeviceMemoryBudgetPropertiesEXT
public VkPhysicalDeviceMemoryBudgetPropertiesEXT(java.nio.ByteBuffer container)
Creates aVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance at the current position of the specifiedByteBuffer
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.
-
-
Method Detail
-
sizeof
public int sizeof()
- Specified by:
sizeof
in classorg.lwjgl.system.Struct
-
sType
public int sType()
Returns the value of thesType
field.
-
pNext
public long pNext()
Returns the value of thepNext
field.
-
heapBudget
public java.nio.LongBuffer heapBudget()
Returns aLongBuffer
view of theheapBudget
field.
-
heapBudget
public long heapBudget(int index)
Returns the value at the specified index of theheapBudget
field.
-
heapUsage
public java.nio.LongBuffer heapUsage()
Returns aLongBuffer
view of theheapUsage
field.
-
heapUsage
public long heapUsage(int index)
Returns the value at the specified index of theheapUsage
field.
-
sType
public VkPhysicalDeviceMemoryBudgetPropertiesEXT sType(int value)
Sets the specified value to thesType
field.
-
pNext
public VkPhysicalDeviceMemoryBudgetPropertiesEXT pNext(long value)
Sets the specified value to thepNext
field.
-
set
public VkPhysicalDeviceMemoryBudgetPropertiesEXT set(int sType, long pNext)
Initializes this struct with the specified values.
-
set
public VkPhysicalDeviceMemoryBudgetPropertiesEXT set(VkPhysicalDeviceMemoryBudgetPropertiesEXT src)
Copies the specified struct data to this struct.- Parameters:
src
- the source struct- Returns:
- this struct
-
malloc
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT malloc()
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated withmemAlloc
. The instance must be explicitly freed.
-
calloc
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT calloc()
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated withmemCalloc
. The instance must be explicitly freed.
-
create
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT create()
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated withBufferUtils
.
-
create
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT create(long address)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance for the specified memory address.
-
createSafe
@Nullable public static VkPhysicalDeviceMemoryBudgetPropertiesEXT createSafe(long address)
-
malloc
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer malloc(int capacity)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated withmemAlloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
calloc
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer calloc(int capacity)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated withmemCalloc
. The instance must be explicitly freed.- Parameters:
capacity
- the buffer capacity
-
create
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer create(int capacity)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated withBufferUtils
.- Parameters:
capacity
- the buffer capacity
-
create
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer create(long address, int capacity)
Create aVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance at the specified memory.- Parameters:
address
- the memory addresscapacity
- the buffer capacity
-
createSafe
@Nullable public static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer createSafe(long address, int capacity)
-
mallocStack
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT mallocStack()
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated on the thread-localMemoryStack
.
-
callocStack
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT callocStack()
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.
-
mallocStack
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT mallocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocate
-
callocStack
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT callocStack(org.lwjgl.system.MemoryStack stack)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocate
-
mallocStack
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer mallocStack(int capacity)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated on the thread-localMemoryStack
.- Parameters:
capacity
- the buffer capacity
-
callocStack
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer callocStack(int capacity)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated on the thread-localMemoryStack
and initializes all its bits to zero.- Parameters:
capacity
- the buffer capacity
-
mallocStack
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer mallocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated on the specifiedMemoryStack
.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
callocStack
public static VkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer callocStack(int capacity, org.lwjgl.system.MemoryStack stack)
Returns a newVkPhysicalDeviceMemoryBudgetPropertiesEXT.Buffer
instance allocated on the specifiedMemoryStack
and initializes all its bits to zero.- Parameters:
stack
- the stack from which to allocatecapacity
- the buffer capacity
-
nsType
public static int nsType(long struct)
Unsafe version ofsType()
.
-
npNext
public static long npNext(long struct)
Unsafe version ofpNext()
.
-
nheapBudget
public static java.nio.LongBuffer nheapBudget(long struct)
Unsafe version ofheapBudget()
.
-
nheapBudget
public static long nheapBudget(long struct, int index)
Unsafe version ofheapBudget
.
-
nheapUsage
public static java.nio.LongBuffer nheapUsage(long struct)
Unsafe version ofheapUsage()
.
-
nheapUsage
public static long nheapUsage(long struct, int index)
Unsafe version ofheapUsage
.
-
nsType
public static void nsType(long struct, int value)
Unsafe version ofsType
.
-
npNext
public static void npNext(long struct, long value)
Unsafe version ofpNext
.
-
-