Vulkan Memory Allocator
|
VmaAllocator
objects can be used independently. There should be no need to create multiple such objects though - one per VkDevice
is enough.VmaAllocator
as first parameter are safe to call from multiple threads simultaneously because they are synchronized internally when needed.VmaAllocator
object must be synchronized externally.VmaAllocation
object must be externally synchronized. For example, you must not call vmaGetAllocationInfo() and vmaMapMemory() from different threads at the same time if you pass the same VmaAllocation
object to these functions.The library uses following algorithm for allocation, in order:
VkDeviceMemory
, with preferred block size.VkDeviceMemory
for this allocation, just like when you use VMA_ALLOCATION_CREATE_DEDICATED_MEMORY_BIT.VK_ERROR_OUT_OF_DEVICE_MEMORY
.Features deliberately excluded from the scope of this library:
VkCommandList
or VkCommandQueue
and related synchronization is responsibility of the user.