Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Implement GPUBuffer.mapAsync and update wgpu-core
  • Loading branch information
kunalmohan committed Jun 27, 2020
1 parent 0afe412 commit b74cea3
Show file tree
Hide file tree
Showing 18 changed files with 509 additions and 428 deletions.
59 changes: 27 additions & 32 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion components/script/dom/bindings/codegen/Bindings.conf
Expand Up @@ -153,7 +153,7 @@ DOMInterfaces = {
},

'GPUBuffer': {
'inRealms': ['MapReadAsync'],
'inRealms': ['MapAsync'],
}

}
12 changes: 7 additions & 5 deletions components/script/dom/bindings/trace.rs
Expand Up @@ -165,10 +165,11 @@ use tendril::{StrTendril, TendrilSink};
use time::{Duration, Timespec, Tm};
use uuid::Uuid;
use webgpu::{
wgpu::command::RawPass, wgpu::id, WebGPU, WebGPUAdapter, WebGPUBindGroup,
WebGPUBindGroupLayout, WebGPUBuffer, WebGPUCommandBuffer, WebGPUCommandEncoder,
WebGPUComputePipeline, WebGPUDevice, WebGPUPipelineLayout, WebGPUQueue, WebGPURenderPipeline,
WebGPUSampler, WebGPUShaderModule, WebGPUTexture, WebGPUTextureView,
wgpu::command::{ComputePass, RenderPass},
WebGPU, WebGPUAdapter, WebGPUBindGroup, WebGPUBindGroupLayout, WebGPUBuffer,
WebGPUCommandBuffer, WebGPUCommandEncoder, WebGPUComputePipeline, WebGPUDevice,
WebGPUPipelineLayout, WebGPUQueue, WebGPURenderPipeline, WebGPUSampler, WebGPUShaderModule,
WebGPUTexture, WebGPUTextureView,
};
use webrender_api::{DocumentId, ExternalImageId, ImageKey};
use webxr_api::SwapChainId as WebXRSwapChainId;
Expand Down Expand Up @@ -581,7 +582,8 @@ unsafe_no_jsmanaged_fields!(WebGPUContextId);
unsafe_no_jsmanaged_fields!(WebGPUCommandBuffer);
unsafe_no_jsmanaged_fields!(WebGPUCommandEncoder);
unsafe_no_jsmanaged_fields!(WebGPUDevice);
unsafe_no_jsmanaged_fields!(Option<RawPass<id::CommandEncoderId>>);
unsafe_no_jsmanaged_fields!(Option<RenderPass>);
unsafe_no_jsmanaged_fields!(Option<ComputePass>);
unsafe_no_jsmanaged_fields!(GPUBufferState);
unsafe_no_jsmanaged_fields!(GPUCommandEncoderState);
unsafe_no_jsmanaged_fields!(WebXRSwapChainId);
Expand Down

0 comments on commit b74cea3

Please sign in to comment.