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

Unified Diff: cc/output/overlay_candidate.h

Issue 1373373003: Mac Overlays: Add AllOrNothing strategy (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@OverlayTest
Patch Set: Rebase off master Created 5 years, 3 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
« no previous file with comments | « cc/cc.gyp ('k') | cc/output/overlay_candidate.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/output/overlay_candidate.h
diff --git a/cc/output/overlay_candidate.h b/cc/output/overlay_candidate.h
index 28ecfabe184b7eb8cb757d1aa0885d59ed818f69..f54a7ddf113c31dbdb5d026827f821528a4e1049 100644
--- a/cc/output/overlay_candidate.h
+++ b/cc/output/overlay_candidate.h
@@ -21,18 +21,16 @@ class Rect;
namespace cc {
+class DrawQuad;
+class IOSurfaceDrawQuad;
+class StreamVideoDrawQuad;
+class TextureDrawQuad;
+
class CC_EXPORT OverlayCandidate {
public:
- static gfx::OverlayTransform GetOverlayTransform(
- const gfx::Transform& quad_transform,
- bool y_flipped);
- // Apply transform |delta| to |in| and return the resulting transform,
- // or OVERLAY_TRANSFORM_INVALID.
- static gfx::OverlayTransform ModifyTransform(gfx::OverlayTransform in,
- gfx::OverlayTransform delta);
- static gfx::RectF GetOverlayRect(const gfx::Transform& quad_transform,
- const gfx::Rect& rect);
-
+ // Returns true and fills in |candidate| if |draw_quad| is of a known quad
+ // type and contains an overlayable resource.
+ static bool FromDrawQuad(const DrawQuad* quad, OverlayCandidate* candidate);
OverlayCandidate();
~OverlayCandidate();
@@ -65,6 +63,14 @@ class CC_EXPORT OverlayCandidate {
// To be modified by the implementer if this candidate can go into
// an overlay.
bool overlay_handled;
+
+ private:
+ static bool FromTextureQuad(const TextureDrawQuad* quad,
+ OverlayCandidate* candidate);
+ static bool FromStreamVideoQuad(const StreamVideoDrawQuad* quad,
+ OverlayCandidate* candidate);
+ static bool FromIOSurfaceQuad(const IOSurfaceDrawQuad* quad,
+ OverlayCandidate* candidate);
};
typedef std::vector<OverlayCandidate> OverlayCandidateList;
« no previous file with comments | « cc/cc.gyp ('k') | cc/output/overlay_candidate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698