mirror of
https://github.com/gfx-rs/wgpu.git
synced 2026-04-22 03:02:01 -04:00
Merge #1167
1167: Remove temporary allocation for gpu-descriptor r=kvark a=kvark This is no longer needed as https://github.com/zakarumych/gpu-descriptor/pull/10 is merged Co-authored-by: Dzmitry Malyshau <kvarkus@gmail.com>
This commit is contained in:
@@ -141,13 +141,11 @@ impl<B: hal::Backend>
|
||||
unsafe fn alloc_descriptor_sets<'a>(
|
||||
&self,
|
||||
pool: &mut B::DescriptorPool,
|
||||
layouts: impl Iterator<Item = &'a B::DescriptorSetLayout>,
|
||||
layouts: impl ExactSizeIterator<Item = &'a B::DescriptorSetLayout>,
|
||||
sets: &mut impl Extend<B::DescriptorSet>,
|
||||
) -> Result<(), gpu_descriptor::DeviceAllocationError> {
|
||||
use gpu_descriptor::DeviceAllocationError as Dae;
|
||||
//TODO: https://github.com/zakarumych/gpu-descriptor/pull/10
|
||||
let temp_layouts = layouts.collect::<Vec<_>>();
|
||||
match hal::pso::DescriptorPool::allocate(pool, temp_layouts, sets) {
|
||||
match hal::pso::DescriptorPool::allocate(pool, layouts, sets) {
|
||||
Ok(()) => Ok(()),
|
||||
Err(hal::pso::AllocationError::OutOfMemory(oom)) => Err(match oom {
|
||||
hal::device::OutOfMemory::Host => Dae::OutOfHostMemory,
|
||||
|
||||
Reference in New Issue
Block a user