OLD | NEW |
---|---|
1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 module blink.mojom; | 5 module blink.mojom; |
6 | 6 |
7 import "cc/ipc/compositor_frame.mojom"; | 7 import "cc/ipc/compositor_frame.mojom"; |
8 import "cc/ipc/frame_sink_id.mojom"; | |
8 import "cc/ipc/mojo_compositor_frame_sink.mojom"; | 9 import "cc/ipc/mojo_compositor_frame_sink.mojom"; |
9 import "cc/ipc/surface_id.mojom"; | 10 import "cc/ipc/surface_id.mojom"; |
10 import "cc/ipc/surface_sequence.mojom"; | 11 import "cc/ipc/surface_sequence.mojom"; |
11 | 12 |
12 interface OffscreenCanvasSurface { | 13 interface OffscreenCanvasSurface { |
13 // TODO(619138): Make creation of surface id Async after implementation | |
14 // change on surface_id generator that makes client side be able to generate | |
15 // unique surface_id.id_namespace alone. | |
16 [Sync] | |
17 GetSurfaceId() => (cc.mojom.SurfaceId surface_id); | |
18 | |
19 Require(cc.mojom.SurfaceId surface_id, cc.mojom.SurfaceSequence sequence); | 14 Require(cc.mojom.SurfaceId surface_id, cc.mojom.SurfaceSequence sequence); |
20 Satisfy(cc.mojom.SurfaceSequence sequence); | 15 Satisfy(cc.mojom.SurfaceSequence sequence); |
21 }; | 16 }; |
22 | 17 |
18 interface OffscreenCanvasSurfaceClient { | |
19 // TODO(fsamuel, xlai): Replace this with DisplayCompositorClient | |
20 OnSurfaceCreated(cc.mojom.SurfaceId surface_id, | |
21 int32 width, | |
22 int32 height, | |
23 float device_scale_factor); | |
24 }; | |
25 | |
26 interface OffscreenCanvasSurfaceFactory { | |
27 CreateOffscreenCanvasSurface(cc.mojom.FrameSinkId frame_sink_id, | |
28 OffscreenCanvasSurfaceClient client, | |
29 OffscreenCanvasSurface& service); | |
30 }; | |
31 | |
23 interface OffscreenCanvasCompositorFrameSinkProvider { | 32 interface OffscreenCanvasCompositorFrameSinkProvider { |
33 // TODO(fsamuel, xlai): Replace this with DisplayCompositor | |
24 CreateCompositorFrameSink(cc.mojom.SurfaceId surface_id, | 34 CreateCompositorFrameSink(cc.mojom.SurfaceId surface_id, |
Fady Samuel
2016/12/15 22:28:12
This should only take in a FrameSinkId
xlai (Olivia)
2016/12/15 22:46:28
Done.
| |
25 cc.mojom.MojoCompositorFrameSinkClient client, | 35 cc.mojom.MojoCompositorFrameSinkClient client, |
26 cc.mojom.MojoCompositorFrameSink& sink); | 36 cc.mojom.MojoCompositorFrameSink& sink); |
27 }; | 37 }; |
28 | 38 |
OLD | NEW |