aboutsummaryrefslogtreecommitdiffstats
path: root/components/script/dom/gpurenderpipeline.rs
diff options
context:
space:
mode:
authorKunal Mohan <kunalmohan99@gmail.com>2020-07-22 17:52:49 +0530
committerKunal Mohan <kunalmohan99@gmail.com>2020-07-24 12:45:23 +0530
commitaff22db33ff237e0fd677671851e3919007f20ef (patch)
treeb3073acf157f99a004c53d33d7da3d839e5accd1 /components/script/dom/gpurenderpipeline.rs
parent75abccb16bc19eb375ce73f26a0234e3d2ecbb9b (diff)
downloadservo-aff22db33ff237e0fd677671851e3919007f20ef.tar.gz
servo-aff22db33ff237e0fd677671851e3919007f20ef.zip
Implement GPURenderBundleEncoder and GPURenderBundle
Diffstat (limited to 'components/script/dom/gpurenderpipeline.rs')
-rw-r--r--components/script/dom/gpurenderpipeline.rs15
1 files changed, 12 insertions, 3 deletions
diff --git a/components/script/dom/gpurenderpipeline.rs b/components/script/dom/gpurenderpipeline.rs
index 88e55848b91..bb618a248a9 100644
--- a/components/script/dom/gpurenderpipeline.rs
+++ b/components/script/dom/gpurenderpipeline.rs
@@ -21,10 +21,14 @@ pub struct GPURenderPipeline {
}
impl GPURenderPipeline {
- fn new_inherited(render_pipeline: WebGPURenderPipeline, device: WebGPUDevice) -> Self {
+ fn new_inherited(
+ render_pipeline: WebGPURenderPipeline,
+ device: WebGPUDevice,
+ label: Option<USVString>,
+ ) -> Self {
Self {
reflector_: Reflector::new(),
- label: DomRefCell::new(None),
+ label: DomRefCell::new(label),
render_pipeline,
device,
}
@@ -34,9 +38,14 @@ impl GPURenderPipeline {
global: &GlobalScope,
render_pipeline: WebGPURenderPipeline,
device: WebGPUDevice,
+ label: Option<USVString>,
) -> DomRoot<Self> {
reflect_dom_object(
- Box::new(GPURenderPipeline::new_inherited(render_pipeline, device)),
+ Box::new(GPURenderPipeline::new_inherited(
+ render_pipeline,
+ device,
+ label,
+ )),
global,
)
}