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

Unified Diff: gpu/ipc/service/gpu_command_buffer_stub.cc

Issue 2628963002: Revert of Enable creation of offscreen contexts which own their backing surface. (Closed)
Patch Set: Created 3 years, 11 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: gpu/ipc/service/gpu_command_buffer_stub.cc
diff --git a/gpu/ipc/service/gpu_command_buffer_stub.cc b/gpu/ipc/service/gpu_command_buffer_stub.cc
index 1ee0cae4bb2a7db7973ff029be344a1f07abba86..3f41a30555095398eacb3ddab053551bfa5bfb3d 100644
--- a/gpu/ipc/service/gpu_command_buffer_stub.cc
+++ b/gpu/ipc/service/gpu_command_buffer_stub.cc
@@ -623,32 +623,7 @@
decoder_->set_engine(executor_.get());
if (offscreen) {
- if (init_params.attribs.own_offscreen_surface) {
- DVLOG(1) << __FUNCTION__ << "Hit the own_offscreen_surface path";
- use_virtualized_gl_context_ = false;
- // Currently, we can't separately control alpha channel for surfaces,
- // it's generally enabled by default except for RGB565 and (on desktop)
- // smaller-than-32bit formats.
- //
- // TODO(klausw): use init_params.attribs.alpha_size here if possible.
- if (init_params.attribs.depth_size > 0) {
- surface_format.SetDepthBits(init_params.attribs.depth_size);
- }
- if (init_params.attribs.samples > 0) {
- surface_format.SetSamples(init_params.attribs.samples);
- }
- if (init_params.attribs.stencil_size > 0) {
- surface_format.SetStencilBits(init_params.attribs.stencil_size);
- }
- surface_ = gl::init::CreateOffscreenGLSurfaceWithFormat(
- gfx::Size(), surface_format);
- if (!surface_) {
- DLOG(ERROR) << "Failed to create surface.";
- return false;
- }
- } else {
- surface_ = default_surface;
- }
+ surface_ = default_surface;
} else {
surface_ = ImageTransportSurface::CreateNativeSurface(
AsWeakPtr(), surface_handle_, surface_format);

Powered by Google App Engine
This is Rietveld 408576698