mirror of
https://github.com/servo/servo.git
synced 2025-06-10 09:33:13 +00:00
webgpu: Sync GPUBuffer
(#33154)
* More helpers on `Promise` Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com> * Sync `GPUBuffer` Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com> * Set some good expectations Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com> * Some bad expect also on firefox Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com> * Extract DataBlock, DataView impl from GPUBuffer Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com> * Fix size check to work on 32bit platforms Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com> --------- Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
This commit is contained in:
parent
bb5926b329
commit
7fce24f9d5
12 changed files with 690 additions and 1163 deletions
|
@ -8,7 +8,7 @@ use std::hash::{Hash, Hasher};
|
|||
use dom_struct::dom_struct;
|
||||
use webgpu::{WebGPU, WebGPUCommandBuffer, WebGPURequest};
|
||||
|
||||
use crate::dom::bindings::cell::{DomRefCell, Ref};
|
||||
use crate::dom::bindings::cell::DomRefCell;
|
||||
use crate::dom::bindings::codegen::Bindings::WebGPUBinding::GPUCommandBufferMethods;
|
||||
use crate::dom::bindings::reflector::{reflect_dom_object, Reflector};
|
||||
use crate::dom::bindings::root::{Dom, DomRoot};
|
||||
|
@ -89,10 +89,6 @@ impl GPUCommandBuffer {
|
|||
pub fn id(&self) -> WebGPUCommandBuffer {
|
||||
self.command_buffer
|
||||
}
|
||||
|
||||
pub fn buffers(&self) -> Ref<HashSet<Dom<GPUBuffer>>> {
|
||||
self.buffers.borrow()
|
||||
}
|
||||
}
|
||||
|
||||
impl GPUCommandBufferMethods for GPUCommandBuffer {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue