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

Unified Diff: cc/output/output_surface.cc

Issue 53633003: Do not give GPU memory to backgrounded compositors. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Remove test Created 7 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/output/output_surface.h ('k') | cc/output/output_surface_client.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: cc/output/output_surface.cc
diff --git a/cc/output/output_surface.cc b/cc/output/output_surface.cc
index 002a44a37eb3f2a5f3ceaa437d959f006402321b..f7b3b36219b6da5cc0a0994d2744d1120f6fdf5a 100644
--- a/cc/output/output_surface.cc
+++ b/cc/output/output_surface.cc
@@ -489,17 +489,14 @@ void OutputSurface::PostSwapBuffersComplete() {
weak_ptr_factory_.GetWeakPtr()));
}
-void OutputSurface::SetMemoryPolicy(const ManagedMemoryPolicy& policy,
- bool discard_backbuffer) {
- TRACE_EVENT2("cc", "OutputSurface::SetMemoryPolicy",
- "bytes_limit_when_visible", policy.bytes_limit_when_visible,
- "discard_backbuffer", discard_backbuffer);
+void OutputSurface::SetMemoryPolicy(const ManagedMemoryPolicy& policy) {
+ TRACE_EVENT1("cc", "OutputSurface::SetMemoryPolicy",
+ "bytes_limit_when_visible", policy.bytes_limit_when_visible);
// Just ignore the memory manager when it says to set the limit to zero
// bytes. This will happen when the memory manager thinks that the renderer
// is not visible (which the renderer knows better).
if (policy.bytes_limit_when_visible)
client_->SetMemoryPolicy(policy);
- client_->SetDiscardBackBufferWhenNotVisible(discard_backbuffer);
}
} // namespace cc
« no previous file with comments | « cc/output/output_surface.h ('k') | cc/output/output_surface_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698