pub fn new<F: Fn(&ash::Device) -> VkResult<T> + Send + Sync + 'static>(
        max_in_flight_frames: u32,
        max_pool_count: u32,
        allocate_fn: F,
    ) -> Self {
        VkPoolAllocator {
            allocate_fn: Box::new(allocate_fn),
            in_flight_pools: Default::default(),
            reset_pools: Default::default(),
            max_in_flight_frames: Wrapping(max_in_flight_frames),
            frame_index: Wrapping(0),
            created_pool_count: 0,
            max_pool_count,
        }
    }
/// Create a pool allocator that will reset resources after N frames. Keep in mind that if for
/// example you want to push a single resource per frame, up to N+1 resources will exist
/// in the sink. If max_in_flight_frames is 2, then you would have a resource that has
/// likely not been submitted to the GPU yet, plus a resource per the N frames that have
/// been submitted
Create a pool allocator that will reset resources after N frames. Keep in mind that if for
example you want to push a single resource per frame, up to N+1 resources will exist
in the sink. If max_in_flight_frames is 2, then you would have a resource that has
likely not been submitted to the GPU yet, plus a resource per the N frames that have
been submitted
Create a pool allocator that will reset resources after N frames . Keep in mind that if for example you want to push a single resource per frame up to N + 1 resources will exist in the sink . If max_in_flight_frames is 2 then you would have a resource that has likely not been submitted to the GPU yet plus a resource per the N frames that have been submitted
pub fn new<F: Fn(&ash::Device) -> VkResult<T> + Send + Sync + 'static>(
        max_in_flight_frames: u32,
        max_pool_count: u32,
        allocate_fn: F,
    ) -> Self {
        VkPoolAllocator {
            allocate_fn: Box::new(allocate_fn),
            in_flight_pools: Default::default(),
            reset_pools: Default::default(),
            max_in_flight_frames: Wrapping(max_in_flight_frames),
            frame_index: Wrapping(0),
            created_pool_count: 0,
            max_pool_count,
        }
    }
pub fn new < F : Fn ( & ash :: Device ) -> VkResult < T > + Send + Sync + ' static > ( max_in_flight_frames : u32 , max_pool_count : u32 , allocate_fn : F , ) -> Self { VkPoolAllocator { allocate_fn : Box :: new ( allocate_fn ) , in_flight_pools : Default :: default ( ) , reset_pools : Default :: default ( ) , max_in_flight_frames : Wrapping ( max_in_flight_frames ) , frame_index : Wrapping ( 0 ) , created_pool_count : 0 , max_pool_count , } }
Create a pool allocator that will reset resources after N frames.
Create a pool allocator that will reset resources after N frames .
max_in_flight_frames
u32
max_pool_count
u32
allocate_fn
F
max_in_flight_frames
u32
max_pool_count
u32
allocate_fn
F