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

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

Issue 511423002: Use GpuBrowserCompositorOutputSurface with Surfaces. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 4 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 | « no previous file | content/browser/compositor/onscreen_display_client.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/browser/compositor/gpu_process_transport_factory.cc
diff --git a/content/browser/compositor/gpu_process_transport_factory.cc b/content/browser/compositor/gpu_process_transport_factory.cc
index 834287cf8ab72d0ae04d03b0314dad9ad8cb7da8..fe90a7c50fcdb613433eca2ee65401bf75b6e231 100644
--- a/content/browser/compositor/gpu_process_transport_factory.cc
+++ b/content/browser/compositor/gpu_process_transport_factory.cc
@@ -181,23 +181,25 @@ scoped_ptr<cc::OutputSurface> GpuProcessTransportFactory::CreateOutputSurface(
// associated with this context, then return a SurfaceDisplayOutputSurface
// set up to draw to the display's surface.
cc::SurfaceManager* manager = surface_manager_.get();
- scoped_ptr<cc::OutputSurface> software_surface;
+ scoped_ptr<cc::OutputSurface> display_surface;
if (!context_provider.get()) {
- software_surface =
+ display_surface =
make_scoped_ptr(new SoftwareBrowserCompositorOutputSurface(
output_surface_proxy_,
CreateSoftwareOutputDevice(compositor),
per_compositor_data_[compositor]->surface_id,
&output_surface_map_,
compositor->vsync_manager()));
+ } else {
+ display_surface = make_scoped_ptr(new GpuBrowserCompositorOutputSurface(
+ context_provider,
+ per_compositor_data_[compositor]->surface_id,
+ &output_surface_map_,
+ compositor->vsync_manager(),
+ CreateOverlayCandidateValidator(compositor->widget())));
}
- scoped_ptr<OnscreenDisplayClient> display_client(
- new OnscreenDisplayClient(context_provider,
- software_surface.Pass(),
- manager,
- compositor->task_runner()));
- // TODO(jamesr): Need to set up filtering for the
- // GpuHostMsg_UpdateVSyncParameters message.
+ scoped_ptr<OnscreenDisplayClient> display_client(new OnscreenDisplayClient(
+ display_surface.Pass(), manager, compositor->task_runner()));
scoped_refptr<cc::ContextProvider> offscreen_context_provider;
if (context_provider.get()) {
« no previous file with comments | « no previous file | content/browser/compositor/onscreen_display_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698