mirror of
https://github.com/servo/servo.git
synced 2025-07-22 23:03:42 +01:00
Fixing some style related issues in WebGPU.
Changed the Requests/Response from tuples to named struct variants and also sorted in alphabetical order. Replaced the ID generator functions from `globalscope` with a single function, which returns a `RefMut` and can call the appropriate method to generate resource IDs.
This commit is contained in:
parent
0f9b04680a
commit
000a5d543d
10 changed files with 561 additions and 472 deletions
|
@ -64,10 +64,13 @@ impl GPUQueueMethods for GPUQueue {
|
|||
// TODO: Generate error to the ErrorScope
|
||||
return;
|
||||
}
|
||||
let buffer_ids = command_buffers.iter().map(|cb| cb.id().0).collect();
|
||||
let command_buffers = command_buffers.iter().map(|cb| cb.id().0).collect();
|
||||
self.channel
|
||||
.0
|
||||
.send(WebGPURequest::Submit(self.queue.0, buffer_ids))
|
||||
.send(WebGPURequest::Submit {
|
||||
queue_id: self.queue.0,
|
||||
command_buffers,
|
||||
})
|
||||
.unwrap();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue