aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/gpurenderpipeline.rs
diff options
context:
space:
mode:
authortanishka <109246904+taniishkaaa@users.noreply.github.com>2024-10-11 20:27:41 +0530
committerGitHub <noreply@github.com>2024-10-11 14:57:41 +0000
commit8843a0e400745787faf4a23213cbfdf7e2158c73 (patch)
treedad95e1d1d9e4af0274ebcc3228fd25d45061745 /components/script/dom/gpurenderpipeline.rs
parent2a6cfbaaf90a2c0f821473ea59c05ea1332d3f1d (diff)
downloadservo-8843a0e400745787faf4a23213cbfdf7e2158c73.tar.gz
servo-8843a0e400745787faf4a23213cbfdf7e2158c73.zip
clippy: Fix `type_complexity` warnings in `components/script/dom` (#33790)
* clippy: Fix type_complexity warnings in components/script/dom Signed-off-by: taniishkaaa <tanishkasingh2004@gmail.com> * Use explicit & implicit method calls where needed Signed-off-by: taniishkaaa <tanishkasingh2004@gmail.com> * Remove unwrap & pass pipeline_layout Signed-off-by: taniishkaaa <tanishkasingh2004@gmail.com> * Remove unused variable - bgls Signed-off-by: taniishkaaa <tanishkasingh2004@gmail.com> --------- Signed-off-by: taniishkaaa <tanishkasingh2004@gmail.com>
Diffstat (limited to 'components/script/dom/gpurenderpipeline.rs')
-rw-r--r--components/script/dom/gpurenderpipeline.rs7
1 files changed, 3 insertions, 4 deletions
diff --git a/components/script/dom/gpurenderpipeline.rs b/components/script/dom/gpurenderpipeline.rs
index dde7cc8ff38..96de0ffd925 100644
--- a/components/script/dom/gpurenderpipeline.rs
+++ b/components/script/dom/gpurenderpipeline.rs
@@ -4,7 +4,6 @@
use dom_struct::dom_struct;
use ipc_channel::ipc::IpcSender;
-use webgpu::wgc::id::{BindGroupLayoutId, PipelineLayoutId};
use webgpu::wgc::pipeline::RenderPipelineDescriptor;
use webgpu::{WebGPU, WebGPUBindGroupLayout, WebGPURenderPipeline, WebGPURequest, WebGPUResponse};
@@ -16,7 +15,7 @@ use crate::dom::bindings::root::{Dom, DomRoot};
use crate::dom::bindings::str::USVString;
use crate::dom::globalscope::GlobalScope;
use crate::dom::gpubindgrouplayout::GPUBindGroupLayout;
-use crate::dom::gpudevice::GPUDevice;
+use crate::dom::gpudevice::{GPUDevice, PipelineLayout};
#[dom_struct]
pub struct GPURenderPipeline {
@@ -70,7 +69,7 @@ impl GPURenderPipeline {
/// <https://gpuweb.github.io/gpuweb/#dom-gpudevice-createrenderpipeline>
pub fn create(
device: &GPUDevice,
- implicit_ids: Option<(PipelineLayoutId, Vec<BindGroupLayoutId>)>,
+ pipeline_layout: PipelineLayout,
descriptor: RenderPipelineDescriptor<'static>,
async_sender: Option<IpcSender<WebGPUResponse>>,
) -> Fallible<WebGPURenderPipeline> {
@@ -83,7 +82,7 @@ impl GPURenderPipeline {
device_id: device.id().0,
render_pipeline_id,
descriptor,
- implicit_ids,
+ implicit_ids: pipeline_layout.implicit(),
async_sender,
})
.expect("Failed to create WebGPU render pipeline");