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

Side by Side Diff: cc/surfaces/direct_compositor_frame_sink.h

Issue 2691453002: [cc] Track observer status in ExternalBeginFrameSource. (Closed)
Patch Set: Fix comments. Created 3 years, 10 months 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
« no previous file with comments | « cc/scheduler/scheduler.cc ('k') | cc/surfaces/direct_compositor_frame_sink.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 CC_SURFACES_DIRECT_COMPOSITOR_FRAME_SINK_H_ 5 #ifndef CC_SURFACES_DIRECT_COMPOSITOR_FRAME_SINK_H_
6 #define CC_SURFACES_DIRECT_COMPOSITOR_FRAME_SINK_H_ 6 #define CC_SURFACES_DIRECT_COMPOSITOR_FRAME_SINK_H_
7 7
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/threading/thread_checker.h" 9 #include "base/threading/thread_checker.h"
10 #include "cc/output/compositor_frame_sink.h" 10 #include "cc/output/compositor_frame_sink.h"
(...skipping 51 matching lines...) Expand 10 before | Expand all | Expand 10 after
62 private: 62 private:
63 // CompositorFrameSinkSupportClient implementation: 63 // CompositorFrameSinkSupportClient implementation:
64 void DidReceiveCompositorFrameAck() override; 64 void DidReceiveCompositorFrameAck() override;
65 void OnBeginFrame(const BeginFrameArgs& args) override; 65 void OnBeginFrame(const BeginFrameArgs& args) override;
66 void ReclaimResources(const ReturnedResourceArray& resources) override; 66 void ReclaimResources(const ReturnedResourceArray& resources) override;
67 void WillDrawSurface(const LocalSurfaceId& local_surface_id, 67 void WillDrawSurface(const LocalSurfaceId& local_surface_id,
68 const gfx::Rect& damage_rect) override; 68 const gfx::Rect& damage_rect) override;
69 69
70 // ExternalBeginFrameSourceClient implementation: 70 // ExternalBeginFrameSourceClient implementation:
71 void OnNeedsBeginFrames(bool needs_begin_frame) override; 71 void OnNeedsBeginFrames(bool needs_begin_frame) override;
72 void OnDidFinishFrame(const BeginFrameAck& ack) override;
72 73
73 // This class is only meant to be used on a single thread. 74 // This class is only meant to be used on a single thread.
74 base::ThreadChecker thread_checker_; 75 base::ThreadChecker thread_checker_;
75 76
76 const FrameSinkId frame_sink_id_; 77 const FrameSinkId frame_sink_id_;
77 LocalSurfaceId delegated_local_surface_id_; 78 LocalSurfaceId delegated_local_surface_id_;
78 SurfaceManager* surface_manager_; 79 SurfaceManager* surface_manager_;
79 SurfaceIdAllocator surface_id_allocator_; 80 SurfaceIdAllocator surface_id_allocator_;
80 Display* display_; 81 Display* display_;
81 gfx::Size last_swap_frame_size_; 82 gfx::Size last_swap_frame_size_;
82 bool is_lost_ = false; 83 bool is_lost_ = false;
83 std::unique_ptr<CompositorFrameSinkSupport> support_; 84 std::unique_ptr<CompositorFrameSinkSupport> support_;
84 std::unique_ptr<ExternalBeginFrameSource> begin_frame_source_; 85 std::unique_ptr<ExternalBeginFrameSource> begin_frame_source_;
85 86
86 DISALLOW_COPY_AND_ASSIGN(DirectCompositorFrameSink); 87 DISALLOW_COPY_AND_ASSIGN(DirectCompositorFrameSink);
87 }; 88 };
88 89
89 } // namespace cc 90 } // namespace cc
90 91
91 #endif // CC_SURFACES_DIRECT_COMPOSITOR_FRAME_SINK_H_ 92 #endif // CC_SURFACES_DIRECT_COMPOSITOR_FRAME_SINK_H_
OLDNEW
« no previous file with comments | « cc/scheduler/scheduler.cc ('k') | cc/surfaces/direct_compositor_frame_sink.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698