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

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

Issue 2811813004: Surface Synchronization: Distinguish between dependencies and references (Closed)
Patch Set: Addressed Vlad's comments Created 3 years, 8 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
OLDNEW
1 // Copyright 2017 The Chromium Authors. All rights reserved. 1 // Copyright 2017 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_SURFACE_DEPENDENCY_TRACKER_H_ 5 #ifndef CC_SURFACES_SURFACE_DEPENDENCY_TRACKER_H_
6 #define CC_SURFACES_SURFACE_DEPENDENCY_TRACKER_H_ 6 #define CC_SURFACES_SURFACE_DEPENDENCY_TRACKER_H_
7 7
8 #include "cc/scheduler/begin_frame_source.h" 8 #include "cc/scheduler/begin_frame_source.h"
9 #include "cc/surfaces/pending_frame_observer.h" 9 #include "cc/surfaces/pending_frame_observer.h"
10 #include "cc/surfaces/surface.h" 10 #include "cc/surfaces/surface.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 void RequestSurfaceResolution(Surface* surface); 43 void RequestSurfaceResolution(Surface* surface);
44 44
45 bool has_deadline() const { return frames_since_deadline_set_.has_value(); } 45 bool has_deadline() const { return frames_since_deadline_set_.has_value(); }
46 46
47 // BeginFrameObserver implementation. 47 // BeginFrameObserver implementation.
48 void OnBeginFrame(const BeginFrameArgs& args) override; 48 void OnBeginFrame(const BeginFrameArgs& args) override;
49 const BeginFrameArgs& LastUsedBeginFrameArgs() const override; 49 const BeginFrameArgs& LastUsedBeginFrameArgs() const override;
50 void OnBeginFrameSourcePausedChanged(bool paused) override; 50 void OnBeginFrameSourcePausedChanged(bool paused) override;
51 51
52 // PendingFrameObserver implementation: 52 // PendingFrameObserver implementation:
53 void OnReferencedSurfacesChanged(
54 Surface* surface,
55 const std::vector<SurfaceId>* active_referenced_surfaces,
56 const std::vector<SurfaceId>* pending_referenced_surfaces) override;
57 void OnSurfaceActivated(Surface* surface) override; 53 void OnSurfaceActivated(Surface* surface) override;
58 void OnSurfaceDependenciesChanged( 54 void OnSurfaceDependenciesChanged(
59 Surface* surface, 55 Surface* surface,
60 const SurfaceDependencies& added_dependencies, 56 const SurfaceDependencies& added_dependencies,
61 const SurfaceDependencies& removed_dependencies) override; 57 const SurfaceDependencies& removed_dependencies) override;
62 void OnSurfaceDiscarded(Surface* surface) override; 58 void OnSurfaceDiscarded(Surface* surface) override;
63 59
64 // SurfaceObserver implementation: 60 // SurfaceObserver implementation:
65 void OnSurfaceCreated(const SurfaceInfo& surface_info) override; 61 void OnSurfaceCreated(const SurfaceInfo& surface_info) override;
66 void OnSurfaceDamaged(const SurfaceId& surface_id, bool* changed) override; 62 void OnSurfaceDamaged(const SurfaceId& surface_id, bool* changed) override;
(...skipping 23 matching lines...) Expand all
90 // The set of SurfaceIds corresponding to observed Surfaces that have 86 // The set of SurfaceIds corresponding to observed Surfaces that have
91 // blockers. 87 // blockers.
92 base::flat_set<SurfaceId> observed_surfaces_by_id_; 88 base::flat_set<SurfaceId> observed_surfaces_by_id_;
93 89
94 DISALLOW_COPY_AND_ASSIGN(SurfaceDependencyTracker); 90 DISALLOW_COPY_AND_ASSIGN(SurfaceDependencyTracker);
95 }; 91 };
96 92
97 } // namespace cc 93 } // namespace cc
98 94
99 #endif // CC_SURFACES_SURFACE_DEPENDENCY_TRACKER_H_ 95 #endif // CC_SURFACES_SURFACE_DEPENDENCY_TRACKER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698