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

Unified Diff: content/browser/renderer_host/accelerated_surface_container_mac.h

Issue 8726046: Partial swaps on OSX (Closed) Base URL: backer@fancypants:chromium/src@master
Patch Set: Address reviewer comments. Created 9 years 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 | « no previous file | content/browser/renderer_host/accelerated_surface_container_mac.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/renderer_host/accelerated_surface_container_mac.h
diff --git a/content/browser/renderer_host/accelerated_surface_container_mac.h b/content/browser/renderer_host/accelerated_surface_container_mac.h
index c46430fc6064801fcc8d0a1024719f7e7bcd9dae..1bbf7308888f58e3772828188a90068af523c54c 100644
--- a/content/browser/renderer_host/accelerated_surface_container_mac.h
+++ b/content/browser/renderer_host/accelerated_surface_container_mac.h
@@ -83,10 +83,17 @@ class AcceleratedSurfaceContainerMac {
// Notifies the the container that its surface was painted to.
void set_was_painted_to(uint64 surface_id);
+ void set_was_painted_to(uint64 surface_id,
+ const gfx::Rect& update_rect);
// Notifies the container that its surface is invalid.
void set_surface_invalid() { was_painted_to_ = false; }
private:
+ // Enqueue our texture for later deletion.
+ void EnqueueTextureForDeletion();
+
+ void set_was_painted_to_common(uint64 surface_id);
+
// The manager of this accelerated surface container.
AcceleratedSurfaceContainerManagerMac* manager_;
@@ -129,6 +136,10 @@ class AcceleratedSurfaceContainerMac {
// True if we need to upload the texture again during the next draw.
bool texture_needs_upload_;
+ // The region that was updated via a partial update. |update_rect_.IsEmpty()|
+ // indicates that the whole region was updated.
+ gfx::Rect update_rect_;
+
// This may refer to an old version of the texture if the container is
// resized, for example.
GLuint texture_pending_deletion_;
@@ -140,12 +151,6 @@ class AcceleratedSurfaceContainerMac {
// it before it hasn't been painted to at least once.
bool was_painted_to_;
- // Releases the IOSurface reference, if any, retained by this object.
- void ReleaseIOSurface();
-
- // Enqueue our texture for later deletion.
- void EnqueueTextureForDeletion();
-
DISALLOW_COPY_AND_ASSIGN(AcceleratedSurfaceContainerMac);
};
« no previous file with comments | « no previous file | content/browser/renderer_host/accelerated_surface_container_mac.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698