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

Unified Diff: cc/layer_updater.h

Issue 11266030: Use gfx:: Geometry types for the resource provider and layer updater classes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: uint8 Created 8 years, 2 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/layer_unittest.cc ('k') | cc/prioritized_texture.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/layer_updater.h
diff --git a/cc/layer_updater.h b/cc/layer_updater.h
index 16e1a6ac094bb74c42fb617a0be4c6b416e0783a..bb04a1dba256cf2185e966d2ebcd4ef58619f254 100644
--- a/cc/layer_updater.h
+++ b/cc/layer_updater.h
@@ -9,10 +9,13 @@
#include "cc/prioritized_texture.h"
#include "third_party/khronos/GLES2/gl2.h"
+namespace gfx {
+class Rect;
+class Vector2d;
+}
+
namespace cc {
-class IntRect;
-class IntSize;
class TextureManager;
struct RenderingStats;
class ResourceUpdateQueue;
@@ -28,7 +31,7 @@ public:
void swapTextureWith(scoped_ptr<PrioritizedTexture>& texture) { m_texture.swap(texture); }
// TODO(reveman): partialUpdate should be a property of this class
// instead of an argument passed to update().
- virtual void update(ResourceUpdateQueue&, const IntRect& sourceRect, const IntSize& destOffset, bool partialUpdate, RenderingStats&) = 0;
+ virtual void update(ResourceUpdateQueue&, const gfx::Rect& sourceRect, const gfx::Vector2d& destOffset, bool partialUpdate, RenderingStats&) = 0;
protected:
explicit Resource(scoped_ptr<PrioritizedTexture> texture);
@@ -41,7 +44,7 @@ public:
virtual scoped_ptr<Resource> createResource(PrioritizedTextureManager*) = 0;
// The |resultingOpaqueRect| gives back a region of the layer that was painted opaque. If the layer is marked opaque in the updater,
// then this region should be ignored in preference for the entire layer's area.
- virtual void prepareToUpdate(const IntRect& contentRect, const IntSize& tileSize, float contentsWidthScale, float contentsHeightScale, IntRect& resultingOpaqueRect, RenderingStats&) { }
+ virtual void prepareToUpdate(const gfx::Rect& contentRect, const gfx::Size& tileSize, float contentsWidthScale, float contentsHeightScale, gfx::Rect& resultingOpaqueRect, RenderingStats&) { }
// Set true by the layer when it is known that the entire output is going to be opaque.
virtual void setOpaque(bool) { }
« no previous file with comments | « cc/layer_unittest.cc ('k') | cc/prioritized_texture.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698