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

Unified Diff: cc/output/overlay_processor.h

Issue 1304303002: Mac Overlays: Add sandwich strategy (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@overlay_debug
Patch Set: Ready for pre-review Created 5 years, 4 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 side-by-side diff with in-line comments
Download patch
Index: cc/output/overlay_processor.h
diff --git a/cc/output/overlay_processor.h b/cc/output/overlay_processor.h
index e37816c9565658c00778318d6c2c30d07f6e8f81..d18d6a0d581dc418a86276b466ba0e011866003a 100644
--- a/cc/output/overlay_processor.h
+++ b/cc/output/overlay_processor.h
@@ -17,6 +17,13 @@ class ResourceProvider;
class CC_EXPORT OverlayProcessor {
public:
+ // State from the renderer that is relevant to the overlay processor
+ // strategies.
+ struct CC_EXPORT RendererState {
+ RendererState();
+ ~RendererState();
+ float device_scale_factor;
+ };
class CC_EXPORT Strategy {
public:
virtual ~Strategy() {}
@@ -24,7 +31,8 @@ class CC_EXPORT OverlayProcessor {
// current set of render passes. Returns true if the strategy was successful
// and adds any additional passes necessary to represent overlays to
// |render_passes_in_draw_order|.
- virtual bool Attempt(RenderPassList* render_passes_in_draw_order,
+ virtual bool Attempt(const RendererState& renderer_state,
+ RenderPassList* render_passes_in_draw_order,
OverlayCandidateList* candidates) = 0;
};
typedef ScopedPtrVector<Strategy> StrategyList;
@@ -34,7 +42,8 @@ class CC_EXPORT OverlayProcessor {
// Virtual to allow testing different strategies.
virtual void Initialize();
- void ProcessForOverlays(RenderPassList* render_passes_in_draw_order,
+ void ProcessForOverlays(const RendererState& renderer_state,
+ RenderPassList* render_passes_in_draw_order,
OverlayCandidateList* candidate_list);
protected:

Powered by Google App Engine
This is Rietveld 408576698