Class VmaPoolStats

  • All Implemented Interfaces:
    java.lang.AutoCloseable, org.lwjgl.system.NativeResource, org.lwjgl.system.Pointer

    public class VmaPoolStats
    extends org.lwjgl.system.Struct
    implements org.lwjgl.system.NativeResource
    Describes parameter of existing VmaPool.

    Layout

    
     struct VmaPoolStats {
         VkDeviceSize size();
         VkDeviceSize unusedSize();
         size_t allocationCount();
         size_t unusedRangeCount();
         size_t blockCount();
     }
    • Field Detail

      • SIZEOF

        The struct size in bytes.
      • ALIGNOF

        The struct alignment in bytes.
      • SIZE, UNUSEDSIZE, ALLOCATIONCOUNT, UNUSEDRANGECOUNT, BLOCKCOUNT

        The struct member offsets.
    • Constructor Detail

      • VmaPoolStats

        public VmaPoolStats​(java.nio.ByteBuffer container)
        Creates a VmaPoolStats 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.

    • Method Detail

      • sizeof

        public int sizeof()
        Specified by:
        sizeof in class org.lwjgl.system.Struct
      • size

        public long size()
        total amount of VkDeviceMemory allocated from Vulkan for this pool, in bytes
      • unusedSize

        public long unusedSize()
        total number of bytes in the pool not used by any VmaAllocation
      • allocationCount

        public long allocationCount()
        number of VmaAllocation objects created from this pool that were not destroyed
      • unusedRangeCount

        public long unusedRangeCount()
        number of continuous memory ranges in the pool not used by any VmaAllocation
      • blockCount

        public long blockCount()
        number of VkDeviceMemory blocks allocated for this pool
      • malloc

        public static VmaPoolStats malloc()
        Returns a new VmaPoolStats instance allocated with memAlloc. The instance must be explicitly freed.
      • calloc

        public static VmaPoolStats calloc()
        Returns a new VmaPoolStats instance allocated with memCalloc. The instance must be explicitly freed.
      • create

        public static VmaPoolStats create()
        Returns a new VmaPoolStats instance allocated with BufferUtils.
      • create

        public static VmaPoolStats create​(long address)
        Returns a new VmaPoolStats instance for the specified memory address.
      • createSafe

        @Nullable
        public static VmaPoolStats createSafe​(long address)
        Like create, but returns null if address is NULL.
      • malloc

        public static VmaPoolStats.Buffer malloc​(int capacity)
        Returns a new VmaPoolStats.Buffer instance allocated with memAlloc. The instance must be explicitly freed.
        Parameters:
        capacity - the buffer capacity
      • calloc

        public static VmaPoolStats.Buffer calloc​(int capacity)
        Returns a new VmaPoolStats.Buffer instance allocated with memCalloc. The instance must be explicitly freed.
        Parameters:
        capacity - the buffer capacity
      • create

        public static VmaPoolStats.Buffer create​(long address,
                                                 int capacity)
        Create a VmaPoolStats.Buffer instance at the specified memory.
        Parameters:
        address - the memory address
        capacity - the buffer capacity
      • createSafe

        @Nullable
        public static VmaPoolStats.Buffer createSafe​(long address,
                                                     int capacity)
        Like create, but returns null if address is NULL.
      • mallocStack

        @Deprecated
        public static VmaPoolStats mallocStack​(org.lwjgl.system.MemoryStack stack)
        Deprecated.
        Deprecated for removal in 3.4.0. Use malloc(MemoryStack) instead.
      • callocStack

        @Deprecated
        public static VmaPoolStats callocStack​(org.lwjgl.system.MemoryStack stack)
        Deprecated.
        Deprecated for removal in 3.4.0. Use calloc(MemoryStack) instead.
      • malloc

        public static VmaPoolStats malloc​(org.lwjgl.system.MemoryStack stack)
        Returns a new VmaPoolStats instance allocated on the specified MemoryStack.
        Parameters:
        stack - the stack from which to allocate
      • calloc

        public static VmaPoolStats calloc​(org.lwjgl.system.MemoryStack stack)
        Returns a new VmaPoolStats instance allocated on the specified MemoryStack and initializes all its bits to zero.
        Parameters:
        stack - the stack from which to allocate
      • malloc

        public static VmaPoolStats.Buffer malloc​(int capacity,
                                                 org.lwjgl.system.MemoryStack stack)
        Returns a new VmaPoolStats.Buffer instance allocated on the specified MemoryStack.
        Parameters:
        stack - the stack from which to allocate
        capacity - the buffer capacity
      • calloc

        public static VmaPoolStats.Buffer calloc​(int capacity,
                                                 org.lwjgl.system.MemoryStack stack)
        Returns a new VmaPoolStats.Buffer instance allocated on the specified MemoryStack and initializes all its bits to zero.
        Parameters:
        stack - the stack from which to allocate
        capacity - the buffer capacity
      • nsize

        public static long nsize​(long struct)
        Unsafe version of size().
      • nunusedSize

        public static long nunusedSize​(long struct)
        Unsafe version of unusedSize().
      • nallocationCount

        public static long nallocationCount​(long struct)
        Unsafe version of allocationCount().
      • nunusedRangeCount

        public static long nunusedRangeCount​(long struct)
        Unsafe version of unusedRangeCount().
      • nblockCount

        public static long nblockCount​(long struct)
        Unsafe version of blockCount().