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

Unified Diff: cc/output/overlay_candidate_validator.h

Issue 2508203004: Add hints for potential overlay promotion on android. (Closed)
Patch Set: Created 4 years, 1 month 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_candidate_validator.h
diff --git a/cc/output/overlay_candidate_validator.h b/cc/output/overlay_candidate_validator.h
index 09d380b82a9227b13bd343f91c3234ce00dc74bf..401dd547d19372c700ff011256fa0527e89ab870 100644
--- a/cc/output/overlay_candidate_validator.h
+++ b/cc/output/overlay_candidate_validator.h
@@ -8,11 +8,15 @@
#include <vector>
#include "cc/base/cc_export.h"
+#include "cc/base/resource_id.h"
#include "cc/output/overlay_candidate.h"
#include "cc/output/overlay_processor.h"
namespace cc {
+class ResourceProvider;
+class RenderPass;
+
// This class that can be used to answer questions about possible overlay
// configurations for a particular output device.
class CC_EXPORT OverlayCandidateValidator {
@@ -31,6 +35,13 @@ class CC_EXPORT OverlayCandidateValidator {
// coordinates if necessary.
virtual void CheckOverlaySupport(OverlayCandidateList* surfaces) = 0;
+ // Called before beginning a new pass for overlay promotion to clear out any
+ // promotable resources. One must CheckoverlaySupport() again.
+ virtual void ClearPromotableResources() {}
+
+ // Returns whether |resource_id| is promotable.
+ virtual bool IsResourcePromotable(ResourceId resource_id);
+
virtual ~OverlayCandidateValidator() {}
};

Powered by Google App Engine
This is Rietveld 408576698