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

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

Issue 433543002: Add a new ozone switch to enable surfaceless output mode. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix typo 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 | « chrome/browser/chromeos/login/chrome_restart_request.cc ('k') | content/browser/gpu/gpu_process_host.cc » ('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 17b05485e2100548e11665e3def068bad5f42db1..6ed6f65ed4cfa53b062bc8d9dcd0d6d6197f4d11 100644
--- a/content/browser/compositor/gpu_process_transport_factory.cc
+++ b/content/browser/compositor/gpu_process_transport_factory.cc
@@ -225,13 +225,21 @@ scoped_ptr<cc::OutputSurface> GpuProcessTransportFactory::CreateOutputSurface(
return surface.PassAs<cc::OutputSurface>();
}
- scoped_ptr<BrowserCompositorOutputSurface> surface(
- new GpuBrowserCompositorOutputSurface(
- context_provider,
- per_compositor_data_[compositor]->surface_id,
- &output_surface_map_,
- compositor->vsync_manager(),
- CreateOverlayCandidateValidator(compositor->widget())));
+ scoped_ptr<BrowserCompositorOutputSurface> surface;
+#if defined(USE_OZONE)
+ if (ui::SurfaceFactoryOzone::GetInstance()->CanShowPrimaryPlaneAsOverlay()) {
+ NOTIMPLEMENTED();
+ return scoped_ptr<cc::OutputSurface>(); // TODO(achaulk) implementation.
danakj 2014/08/08 15:41:20 What's the point of adding this in this CL if it c
achaulk 2014/08/08 15:46:03 It was mostly to show where/how it would be used,
danakj 2014/08/08 15:46:48 Ya, I think it would make sense to add it once it
achaulk 2014/08/08 15:49:21 Done.
+ }
+#endif
+ if (!surface)
danakj 2014/08/08 15:46:48 (btw you'd need {} for this cuz multi-line body.)
+ surface.reset(new GpuBrowserCompositorOutputSurface(
+ context_provider,
+ per_compositor_data_[compositor]->surface_id,
+ &output_surface_map_,
+ compositor->vsync_manager(),
+ CreateOverlayCandidateValidator(compositor->widget())));
+
if (data->reflector.get())
data->reflector->ReattachToOutputSurfaceFromMainThread(surface.get());
« no previous file with comments | « chrome/browser/chromeos/login/chrome_restart_request.cc ('k') | content/browser/gpu/gpu_process_host.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698