Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(113)

Side by Side Diff: content/browser/renderer_host/offscreen_canvas_compositor_frame_sink.h

Issue 2493223002: Change exo::SurfaceFactoryOwner to exo::ExoCompositorFrameSink (Closed)
Patch Set: Moved CompositorFrameSink implementation details in to CompositorFrameSinkSupport; addressed commen… Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 #ifndef CONTENT_BROWSER_RENDERER_HOST_OFFSCREEN_CANVAS_COMPOSITOR_FRAME_SINK_H_ 5 #ifndef CONTENT_BROWSER_RENDERER_HOST_OFFSCREEN_CANVAS_COMPOSITOR_FRAME_SINK_H_
6 #define CONTENT_BROWSER_RENDERER_HOST_OFFSCREEN_CANVAS_COMPOSITOR_FRAME_SINK_H_ 6 #define CONTENT_BROWSER_RENDERER_HOST_OFFSCREEN_CANVAS_COMPOSITOR_FRAME_SINK_H_
7 7
8 #include "cc/surfaces/surface_factory.h" 8 #include "cc/surfaces/surface_factory.h"
9 #include "cc/surfaces/surface_factory_client.h" 9 #include "cc/surfaces/surface_factory_client.h"
10 #include "third_party/WebKit/public/platform/modules/offscreencanvas/offscreen_c anvas_surface.mojom.h" 10 #include "third_party/WebKit/public/platform/modules/offscreencanvas/offscreen_c anvas_surface.mojom.h"
(...skipping 11 matching lines...) Expand all
22 22
23 static void Create(const cc::SurfaceId& surface_id, 23 static void Create(const cc::SurfaceId& surface_id,
24 cc::mojom::MojoCompositorFrameSinkClientPtr client, 24 cc::mojom::MojoCompositorFrameSinkClientPtr client,
25 cc::mojom::MojoCompositorFrameSinkRequest request); 25 cc::mojom::MojoCompositorFrameSinkRequest request);
26 26
27 // cc::mojom::MojoCompositorFrameSink implementation. 27 // cc::mojom::MojoCompositorFrameSink implementation.
28 void SubmitCompositorFrame(const cc::LocalFrameId& local_frame_id, 28 void SubmitCompositorFrame(const cc::LocalFrameId& local_frame_id,
29 cc::CompositorFrame frame) override; 29 cc::CompositorFrame frame) override;
30 void SetNeedsBeginFrame(bool needs_begin_frame) override; 30 void SetNeedsBeginFrame(bool needs_begin_frame) override;
31 void EvictFrame() override; 31 void EvictFrame() override;
32 void Require(const cc::LocalFrameId& local_frame_id,
33 const cc::SurfaceSequence& sequence) override;
34 void Satisfy(const cc::SurfaceSequence& sequence) override;
32 35
33 // cc::SurfaceFactoryClient implementation. 36 // cc::SurfaceFactoryClient implementation.
34 void ReturnResources(const cc::ReturnedResourceArray& resources) override; 37 void ReturnResources(const cc::ReturnedResourceArray& resources) override;
35 void WillDrawSurface(const cc::LocalFrameId& id, 38 void WillDrawSurface(const cc::LocalFrameId& id,
36 const gfx::Rect& damage_rect) override; 39 const gfx::Rect& damage_rect) override;
37 void SetBeginFrameSource(cc::BeginFrameSource* begin_frame_source) override; 40 void SetBeginFrameSource(cc::BeginFrameSource* begin_frame_source) override;
38 41
39 private: 42 private:
40 void DidReceiveCompositorFrameAck(); 43 void DidReceiveCompositorFrameAck();
41 44
42 cc::SurfaceId surface_id_; 45 cc::SurfaceId surface_id_;
43 std::unique_ptr<cc::SurfaceFactory> surface_factory_; 46 std::unique_ptr<cc::SurfaceFactory> surface_factory_;
44 cc::mojom::MojoCompositorFrameSinkClientPtr client_; 47 cc::mojom::MojoCompositorFrameSinkClientPtr client_;
45 int ack_pending_count_ = 0; 48 int ack_pending_count_ = 0;
46 cc::ReturnedResourceArray surface_returned_resources_; 49 cc::ReturnedResourceArray surface_returned_resources_;
47 50
48 DISALLOW_COPY_AND_ASSIGN(OffscreenCanvasCompositorFrameSink); 51 DISALLOW_COPY_AND_ASSIGN(OffscreenCanvasCompositorFrameSink);
49 }; 52 };
50 53
51 } // namespace content 54 } // namespace content
52 55
53 #endif // CONTENT_BROWSER_RENDERER_HOST_OFFSCREEN_CANVAS_COMPOSITOR_FRAME_SINK_ H_ 56 #endif // CONTENT_BROWSER_RENDERER_HOST_OFFSCREEN_CANVAS_COMPOSITOR_FRAME_SINK_ H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698