pub struct MemoryPoolPropeties {
pub flags: AllocatorPoolCreateFlags,
pub memory_type_index: u32,
pub block_size: DeviceSize,
pub min_block_count: usize,
pub max_block_count: usize,
pub priority: f32,
pub min_allocation_alignment: DeviceSize,
}Fields§
§flags: AllocatorPoolCreateFlagsUse combination of VmaPoolCreateFlagBits.
memory_type_index: u32Vulkan memory type index to allocate this pool from.
block_size: DeviceSizeSize of a single VkDeviceMemory block to be allocated as part of this pool, in bytes. Optional.
Specify nonzero to set explicit, constant size of memory blocks used by this pool.
Leave 0 to use default and let the library manage block sizes automatically. Sizes of particular blocks may vary. In this case, the pool will also support dedicated allocations.
min_block_count: usizeMinimum number of blocks to be always allocated in this pool, even if they stay empty.
Set to 0 to have no preallocated blocks and allow the pool be completely empty.
max_block_count: usizeMaximum number of blocks that can be allocated in this pool. Optional.
Set to 0 to use default, which is SIZE_MAX, which means no limit.
Set to same value as VmaPoolCreateInfo::minBlockCount to have fixed amount of memory allocated throughout whole lifetime of this pool.
priority: f32A floating-point value between 0 and 1, indicating the priority of the allocations in this pool relative to other memory allocations.
It is used only when #VMA_ALLOCATOR_CREATE_EXT_MEMORY_PRIORITY_BIT flag was used during creation of the #VmaAllocator object. Otherwise, this variable is ignored.
min_allocation_alignment: DeviceSizeAdditional minimum alignment to be used for all allocations created from this pool. Can be 0.
Leave 0 (default) not to impose any additional alignment. If not 0, it must be a power of two.
It can be useful in cases where alignment returned by Vulkan by functions like vkGetBufferMemoryRequirements is not enough,
e.g. when doing interop with OpenGL.
Implementations§
Source§impl MemoryPoolPropeties
impl MemoryPoolPropeties
pub fn create_info(&self) -> PoolCreateInfo<'_>
pub fn from_create_info(value: &PoolCreateInfo<'_>) -> Self
Trait Implementations§
Source§impl Clone for MemoryPoolPropeties
impl Clone for MemoryPoolPropeties
Source§fn clone(&self) -> MemoryPoolPropeties
fn clone(&self) -> MemoryPoolPropeties
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more