mirror of
https://github.com/servo/servo.git
synced 2025-08-06 14:10:11 +01:00
Implement GPURenderBundleEncoder and GPURenderBundle
This commit is contained in:
parent
75abccb16b
commit
aff22db33f
32 changed files with 676 additions and 115 deletions
|
@ -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,
|
||||
)
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue