Upgrade wgpu-core version to 0.5.0 and implement server-side logic for wgpu id recycling

Remove current implementation of MapReadAsync
This commit is contained in:
Kunal Mohan 2020-05-20 11:28:10 +05:30
parent 1a74382603
commit a4f911699a
15 changed files with 504 additions and 339 deletions

View file

@ -36,12 +36,13 @@ pub struct GPUComputePassEncoder {
}
impl GPUComputePassEncoder {
#[allow(unsafe_code)]
fn new_inherited(channel: WebGPU, parent: &GPUCommandEncoder) -> GPUComputePassEncoder {
GPUComputePassEncoder {
channel,
reflector_: Reflector::new(),
label: DomRefCell::new(None),
raw_pass: RefCell::new(Some(RawPass::new_compute(parent.id().0))),
raw_pass: RefCell::new(Some(unsafe { RawPass::new_compute(parent.id().0) })),
command_encoder: Dom::from_ref(parent),
}
}