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

Unified Diff: content/browser/compositor/gpu_browser_compositor_output_surface.cc

Issue 2693023002: Use SwapBuffersWithBounds on Chromecast (Closed)
Patch Set: Created 3 years, 10 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
Index: content/browser/compositor/gpu_browser_compositor_output_surface.cc
diff --git a/content/browser/compositor/gpu_browser_compositor_output_surface.cc b/content/browser/compositor/gpu_browser_compositor_output_surface.cc
index 8ad8384dbaf8e62208841f95deb10c877d651ceb..ba28a06f56ee14b67cf0f5c9a6ede49d17941948 100644
--- a/content/browser/compositor/gpu_browser_compositor_output_surface.cc
+++ b/content/browser/compositor/gpu_browser_compositor_output_surface.cc
@@ -108,10 +108,12 @@ void GpuBrowserCompositorOutputSurface::SwapBuffers(
}
}
- if (swap_rect == gfx::Rect(frame.size))
- context_provider_->ContextSupport()->Swap();
- else
+ if (swap_rect != gfx::Rect(frame.size))
danakj 2017/02/14 17:28:58 Why did you choose this ordering? I would have as
halliwell 2017/02/15 22:29:04 For now, it seems they are mutually exclusive opti
context_provider_->ContextSupport()->PartialSwapBuffers(swap_rect);
+ else if (!frame.content_bounds.empty())
+ context_provider_->ContextSupport()->SwapWithBounds(frame.content_bounds);
+ else
+ context_provider_->ContextSupport()->Swap();
}
uint32_t GpuBrowserCompositorOutputSurface::GetFramebufferCopyTextureFormat() {

Powered by Google App Engine
This is Rietveld 408576698