aboutsummaryrefslogtreecommitdiffstats
path: root/components/constellation/pipeline.rs
diff options
context:
space:
mode:
authorZakor Gyula <gyula.zakor@h-lab.eu>2019-11-10 14:56:22 +0100
committerZakor Gyula <gyula.zakor@h-lab.eu>2019-11-21 08:30:26 +0100
commit12893aa0102f220f411b273a36ac1b4e25fa0ab7 (patch)
tree37362e455b8a1352fc88d39f8eb87170754c5d06 /components/constellation/pipeline.rs
parent47e39af0f36227e8e98b3dc3511c225192bf3736 (diff)
downloadservo-12893aa0102f220f411b273a36ac1b4e25fa0ab7.tar.gz
servo-12893aa0102f220f411b273a36ac1b4e25fa0ab7.zip
Initial implementation of WebGPU API
Diffstat (limited to 'components/constellation/pipeline.rs')
-rw-r--r--components/constellation/pipeline.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/components/constellation/pipeline.rs b/components/constellation/pipeline.rs
index 3ac5ded15ed..fd7202aa9ec 100644
--- a/components/constellation/pipeline.rs
+++ b/components/constellation/pipeline.rs
@@ -46,6 +46,7 @@ use std::process;
use std::rc::Rc;
use std::sync::atomic::AtomicBool;
use std::sync::Arc;
+use webgpu::WebGPU;
use webvr_traits::WebVRMsg;
/// A `Pipeline` is the constellation's view of a `Document`. Each pipeline has an
@@ -188,6 +189,9 @@ pub struct InitialPipelineState {
/// A channel to the WebGL thread.
pub webgl_chan: Option<WebGLPipeline>,
+ /// A channel to the WebGPU threads.
+ pub webgpu: Option<WebGPU>,
+
/// A channel to the webvr thread.
pub webvr_chan: Option<IpcSender<WebVRMsg>>,
@@ -299,6 +303,7 @@ impl Pipeline {
webrender_document: state.webrender_document,
webgl_chan: state.webgl_chan,
webvr_chan: state.webvr_chan,
+ webgpu: state.webgpu,
webxr_registry: state.webxr_registry,
player_context: state.player_context,
};
@@ -504,6 +509,7 @@ pub struct UnprivilegedPipelineContent {
webrender_api_sender: webrender_api::RenderApiSender,
webrender_document: webrender_api::DocumentId,
webgl_chan: Option<WebGLPipeline>,
+ webgpu: Option<WebGPU>,
webvr_chan: Option<IpcSender<WebVRMsg>>,
webxr_registry: webxr_api::Registry,
player_context: WindowGLContext,
@@ -556,6 +562,7 @@ impl UnprivilegedPipelineContent {
pipeline_namespace_id: self.pipeline_namespace_id,
content_process_shutdown_chan: content_process_shutdown_chan,
webgl_chan: self.webgl_chan,
+ webgpu: self.webgpu,
webvr_chan: self.webvr_chan,
webxr_registry: self.webxr_registry,
webrender_document: self.webrender_document,