mirror of
https://github.com/servo/servo.git
synced 2025-08-05 21:50:18 +01:00
Replace wgpu-native with wgpu-core
This commit is contained in:
parent
250184fe60
commit
e146e6058a
8 changed files with 130 additions and 59 deletions
|
@ -78,16 +78,18 @@ impl GPUAdapterMethods for GPUAdapter {
|
|||
fn RequestDevice(&self, descriptor: &GPUDeviceDescriptor, comp: InCompartment) -> Rc<Promise> {
|
||||
let promise = Promise::new_in_current_compartment(&self.global(), comp);
|
||||
let sender = response_async(&promise, self);
|
||||
let desc = wgpu::DeviceDescriptor {
|
||||
extensions: wgpu::Extensions {
|
||||
let desc = wgpu::instance::DeviceDescriptor {
|
||||
extensions: wgpu::instance::Extensions {
|
||||
anisotropic_filtering: descriptor.extensions.anisotropicFiltering,
|
||||
},
|
||||
limits: wgpu::Limits {
|
||||
limits: wgpu::instance::Limits {
|
||||
max_bind_groups: descriptor.limits.maxBindGroups,
|
||||
},
|
||||
};
|
||||
if let Some(window) = self.global().downcast::<Window>() {
|
||||
let id = window.Navigator().create_device_id();
|
||||
let id = window
|
||||
.Navigator()
|
||||
.create_device_id(self.adapter.0.backend());
|
||||
match window.webgpu_channel() {
|
||||
Some(thread) => thread
|
||||
.0
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue