Project: chromium Issues People Development process History Sign in
New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.
Starred by 5 users
Status: Fixed
Owner:
Closed: Aug 2016
Cc:
EstimatedDays: ----
NextAction: ----
OS: All
Pri: 3
Type: Bug

Blocked on:
issue 650284



Sign in to add a comment
Refactor //ui/gl to fix Ozone dep problem
Project Member Reported by kylec...@chromium.org, May 11 2016 Back to list
Problem
Ozone platforms need to create custom GLSurfaces but //ui/gl/init needs to depend on //ui/ozone. Since //ui/ozone can't know about GLSurface, //ui/ozone defines a new class SurfaceOzoneEGL that duplicates the parts of GLSurface the Ozone platform needs to customize. This leads to an awkward hierarchy, where GLSurfaceOzoneEGL holds a SurfaceOzoneEGL. We want to add GLX support for Ozone X11 which makes this dependency problem even worse.

Solution
It would be much simpler if the Ozone platform could create an instance of GLSurface and override the parts it wants to customize. To allow for this, refactor //ui/gl/init into two parts, //ui/gl/init and //ui/gl. Functions to create new surfaces, contexts and one-off initialization will be moved to //ui/gl/init. Other existing code, including the definition of GLSurface and GLContext, will stay in //ui/gl.

//ui/gl/init will depend on //ui/ozone and then //ui/ozone will depend on //ui/gl. This will allow each Ozone platform to implement GLSurface (and GLContext for GLX) as appropriate.

One-off GL initialization and the creation of new contexts and surfaces is currently done using static functions on GLSurface and GLContext. The following functions will be moved to //ui/gl/init and out of the GLContext and GLSurface classes.
 -gfx::GLContext::CreateGLContext will become gl::init::CreateGLContext
 -gfx::GLSurface::InitializeOneOff will become gl::init::InitializeGLOneOff
 -gfx::GLSurface::CreateViewGLSurface will become gl::init::CreateViewGLSurface
 -gfx::GLSurface::CreateSurfacelessViewGLSurface will become -gl::init::CreateSurfacelessViewGLSurface
 -gfx::GLSurface::CreateOffscreenGLSurface will become gl::init::CreateOffscreenGLSurface

The new functions will be defined in ui/gl/init/gl_factory.h in //ui/gl/init. Each platform will have a gl_factory_<platform>.cc implementation that will be conditionally compiled. All callers will be updated to call the functions defined in gl_factory.h. Build targets that need to initialize GL objects will updated to depend on //ui/gl/init (along with roughly equivalent changes for GYP targets).

Step 1
Create gl_factory.h and a single default gl_factory.cc in //ui/gl/init. The implementation for each function in gl_factory.cc will simply call the equivalent existing static function. 
gl::init::CreateGLContext from //ui/gl/init will call gfx::GLContext::CreateGLContext from //ui/gl. 
gl::init::InitializeGLOneOff from //ui/gl/init will call gfx::GLSurface::InitializeOneOff from //ui/gl. 
gl::init::CreateViewGLSurface from //ui/gl/init will call gfx::GLSurface::CreateViewGLSurface from //ui/gl. 
gl::init::CreateSurfacelessViewGLSurface from //ui/gl/init will call gfx::GLSurface::CreateSurfacelessViewGLSurface from //ui/gl. 
gl::init::CreateOffscreenGLSurface from //ui/gl/init will call gfx::GLSurface::CreateOffscreenGLSurface from //ui/gl. 

All call sites of the of existing functions in //ui/gl will be updated to call the new function in //ui/gl/init. The existing functions will be marked as deprecated. This step will update all call sites without making any logic changes.

Step 2
Create gl_factory_<platform>.cc for android, mac, win, x11 and ozone. Move the implementation for the static functions from gl_surface_<platform>.cc and gl_context_<platform>.cc in //ui/gl to gl_factory_<platform>.cc in //ui/gl/init. Some changes to organization will be required as many GLSurface and GLContext subclasses are hidden in anonymous namespaces. This can be done over multiple CLs on a per platform basis. Once this is finished the existing static functions can be removed and the default gl_factory.cc can be deleted.

There will be some other functions in gl_implementation.h / gl_implementation_<platform>.cc that will need to be moved into //ui/gl/init, including things like initializing GL bindings. These functions will end up in gl_factory.h as well. 

Step 3
SurfaceFactoryOzone will be refactored to create a GLSurface/GLContext instead of creating a SurfaceOzoneEGL. SurfaceOzoneEGL will be deleted. The gl_factory_ozone.cc implementation will then simply call into SurfaceFactoryOzone.
gl::init::CreateGLContext from //ui/gl/init call ui::SurfaceFactoryOzone::CreateGLContext from //ui/ozone
gl::init::CreateViewGLSurface from //ui/gl/init call ui::init::SurfaceFactoryOzone::CreateViewGLSurface from //ui/ozone
gl::init::CreateSurfacelessViewGLSurface from //ui/gl/init call ui::init::SurfaceFactoryOzone::CreateSurfacelessViewGLSurface from //ui/ozone
 
Project Member Comment 1 by bugdroid1@chromium.org, May 16 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5

commit 5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5
Author: kylechar <kylechar@chromium.org>
Date: Mon May 16 15:40:57 2016

Split //ui/gl into //ui/gl + //ui/gi/init.

Refactor //ui/gl to fix Ozone dep problem. This CL is step 1 described
in the associated bug.

BUG=611142
CQ_INCLUDE_TRYBOTS=tryserver.blink:linux_blink_rel

Review-Url: https://codereview.chromium.org/1920163005
Cr-Commit-Position: refs/heads/master@{#393838}

[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/android_webview/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/android_webview/android_webview.gyp
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/android_webview/android_webview_tests.gypi
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/android_webview/browser/aw_gl_surface.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/android_webview/browser/scoped_app_gl_state_restore.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/android_webview/browser/test/fake_window.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/blimp/client/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/blimp/client/app/blimp_startup.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/components/mus/gles2/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/components/mus/gles2/command_buffer_driver.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/components/mus/gles2/gpu_state.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/content/common/sandbox_mac.mm
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/content/content_common.gypi
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/content/content_gpu.gypi
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/content/gpu/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/content/gpu/gpu_child_thread.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/content/gpu/gpu_main.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/command_buffer/service/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/command_buffer/service/in_process_command_buffer.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/command_buffer/tests/gl_manager.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/command_buffer/tests/gl_tests_main.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/command_buffer/tests/gl_unittests_android.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/command_buffer_service.gypi
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/config/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/config/gpu_info_collector.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/gles2_conform_support/egl/context.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/gles2_conform_support/egl/display.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/gles2_conform_support/egl/thread_state.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/gles2_conform_support/gles2_conform_support.gyp
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/gpu.gyp
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/gpu_config.gypi
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/gpu_ipc_client.gypi
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/gpu_ipc_common.gypi
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/gpu_ipc_service.gypi
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/ipc/service/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/ipc/service/gpu_channel_manager.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/ipc/service/gpu_command_buffer_stub.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/ipc/service/image_transport_surface_linux.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/ipc/service/image_transport_surface_win.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/perftests/texture_upload_perftest.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/tools/compositor_model_bench/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/tools/compositor_model_bench/compositor_model_bench.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/gpu/tools/tools.gyp
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/media/gpu/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/media/gpu/rendering_helper.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/media/media_gpu.gypi
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/aura/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/aura/aura.gyp
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/aura/demo/DEPS
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/aura/demo/demo_main.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/generate_bindings.py
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl.gyp
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_bindings_autogen_egl.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_bindings_autogen_gl.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_bindings_autogen_glx.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_bindings_autogen_osmesa.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_bindings_autogen_wgl.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_context.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_context_osmesa.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_context_stub.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_context_stub_with_extensions.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_egl_api_implementation.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_fence_apple.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_fence_arb.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_fence_egl.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_fence_nv.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_image_egl.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_image_io_surface.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_image_memory.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_image_ozone_native_pixmap.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_image_ref_counted_memory.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_image_shared_memory.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_image_stub.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_image_surface_texture.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_surface.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_surface_egl.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_surface_egl_x11.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_surface_mac.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_surface_osmesa.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_surface_stub.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_surface_wgl.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/gl_tests.gyp
[add] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/init/BUILD.gn
[add] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/init/gl_factory.cc
[add] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/init/gl_factory.h
[add] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/init/gl_init.gyp
[add] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/init/gl_init_export.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/gl/test/gl_image_test_template.h
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/ozone/demo/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/ozone/demo/gl_renderer.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/ozone/demo/ozone_demo.cc
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/ozone/demo/ozone_demos.gyp
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/surface/surface.gyp
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/views/examples/BUILD.gn
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/views/examples/DEPS
[modify] https://crrev.com/5b9dec1e9e9a86bf5d5c2acbbfc32597fac300a5/ui/views/examples/examples_main.cc

Project Member Comment 2 by bugdroid1@chromium.org, May 31 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/c192fbb4329e5c5cf106d208ff359f5f085c34f2

commit c192fbb4329e5c5cf106d208ff359f5f085c34f2
Author: kylechar <kylechar@chromium.org>
Date: Tue May 31 20:11:56 2016

Move GLSurfaceOSMesaX11 into it's own source file.

The initialization code in GLSurfaceOSMesaX11 needs to be used from
//ui/gl/init and as such can't be in anonymous namespace. Expose the
class similar to other GLSurface implementations.

BUG=611142

Review-Url: https://codereview.chromium.org/2022103002
Cr-Commit-Position: refs/heads/master@{#396911}

[modify] https://crrev.com/c192fbb4329e5c5cf106d208ff359f5f085c34f2/ui/gl/BUILD.gn
[modify] https://crrev.com/c192fbb4329e5c5cf106d208ff359f5f085c34f2/ui/gl/gl.gyp
[add] https://crrev.com/c192fbb4329e5c5cf106d208ff359f5f085c34f2/ui/gl/gl_surface_osmesa_x11.cc
[add] https://crrev.com/c192fbb4329e5c5cf106d208ff359f5f085c34f2/ui/gl/gl_surface_osmesa_x11.h
[modify] https://crrev.com/c192fbb4329e5c5cf106d208ff359f5f085c34f2/ui/gl/gl_surface_x11.cc

Cc: halliwell@chromium.org
Project Member Comment 4 by bugdroid1@chromium.org, Jun 3 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/7cf286c8a63e8f4146d9d63144dfec321a0108b2

commit 7cf286c8a63e8f4146d9d63144dfec321a0108b2
Author: kylechar <kylechar@chromium.org>
Date: Fri Jun 03 23:27:17 2016

Move GL one-off initialization code.

Move GL one-off initialization from //ui/gl to //ui/gl/init. Create a
new class GLInitializer to contain the platform specific initialization
methods and add platform specific implementation in a conditionally
included file per platform. Remove the existing one-off initialization
code in GLSurface and from platform specific GLSurface files.

This change is part of step two from the associated bug.

BUG=611142

Review-Url: https://codereview.chromium.org/2024953002
Cr-Commit-Position: refs/heads/master@{#397839}

[modify] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/gl_implementation.h
[modify] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/gl_surface.cc
[modify] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/gl_surface.h
[modify] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/gl_surface_android.cc
[modify] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/gl_surface_mac.cc
[modify] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/gl_surface_ozone.cc
[modify] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/gl_surface_win.cc
[modify] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/gl_surface_x11.cc
[modify] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/init/BUILD.gn
[modify] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/init/gl_factory.cc
[modify] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/init/gl_factory.h
[modify] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/init/gl_init.gyp
[add] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/init/gl_initializer.h
[add] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/init/gl_initializer_android.cc
[add] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/init/gl_initializer_mac.cc
[add] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/init/gl_initializer_ozone.cc
[add] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/init/gl_initializer_win.cc
[add] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/init/gl_initializer_x11.cc
[modify] https://crrev.com/7cf286c8a63e8f4146d9d63144dfec321a0108b2/ui/gl/test/gl_surface_test_support.cc

Project Member Comment 5 by bugdroid1@chromium.org, Jun 7 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/872f45f441e8f7ec36b6947d32622918ffe15fae

commit 872f45f441e8f7ec36b6947d32622918ffe15fae
Author: kylechar <kylechar@chromium.org>
Date: Tue Jun 07 18:27:42 2016

Move GLContext creation from //ui/gl to //ui/gl/init.

Move the code that performs GLContext creation to the new target. Remove
the old code and delete the static method from GLContext entirely.

This adds gl_factory_<platform>.cc files for all platforms. These
platform specific files will have GLSurface creation code added next.

Add InitializeGLContext() function to simplify a common pattern that is
repeated frequently. When a new GLContext is created, it's wrapped in a
scoped_refptr and then initialized. If initialization fails nullptr is
returned instead. Encapsulate this logic into a function instead of
repeating it.

There is one code change in GLSurfaceEGL::InitalizeOneOff(). It creates
a GLContext to test if surfaceless contexts are supported. It can no
longer use the deleted method in GLContext. All platforms that hit this
code path will end up creating a GLContextEGL, so just directly
instantiate it.

This change is part of step two from the associated bug.

BUG=611142

Review-Url: https://codereview.chromium.org/2037793002
Cr-Commit-Position: refs/heads/master@{#398350}

[modify] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/BUILD.gn
[modify] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/gl.gyp
[modify] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/gl_context.cc
[modify] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/gl_context.h
[modify] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/gl_context_cgl.h
[modify] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/gl_context_egl.h
[delete] https://crrev.com/26db34d5889988990938d46d99a02859481ad539/ui/gl/gl_context_mac.mm
[delete] https://crrev.com/26db34d5889988990938d46d99a02859481ad539/ui/gl/gl_context_ozone.cc
[modify] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/gl_context_wgl.h
[delete] https://crrev.com/26db34d5889988990938d46d99a02859481ad539/ui/gl/gl_context_win.cc
[delete] https://crrev.com/26db34d5889988990938d46d99a02859481ad539/ui/gl/gl_context_x11.cc
[modify] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/gl_surface_egl.cc
[modify] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/init/BUILD.gn
[modify] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/init/gl_factory.cc
[rename] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/init/gl_factory_android.cc
[add] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/init/gl_factory_mac.cc
[add] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/init/gl_factory_ozone.cc
[add] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/init/gl_factory_win.cc
[add] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/init/gl_factory_x11.cc
[modify] https://crrev.com/872f45f441e8f7ec36b6947d32622918ffe15fae/ui/gl/init/gl_init.gyp

Project Member Comment 6 by bugdroid1@chromium.org, Jun 10 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f1f2cba219ff4ee3071c716f7add731a5c9e39ca

commit f1f2cba219ff4ee3071c716f7add731a5c9e39ca
Author: kylechar <kylechar@chromium.org>
Date: Fri Jun 10 15:41:06 2016

Move GLSurface creation from //ui/gl to //ui/gl/init.

Move the code that performs GLSurface creation to the new target. Remove
old surface creation code and delete static methods from GLSurface.

Add InitializeGLSurface() function to simplify a common pattern. When a
new GLSurface is created, it is wrapped in a scoped_refptr and then
initialized. If initialization fails nullptr is returned instead.
Encapsulate this logic into a function instead of repeating it.

There are three Ozone related GLSurface subclasses that defined in an
anonymous namespace. Instead of moving the class definitions to a header
file, public functions are added to create these types, as the classes
need to be refactored heavily.

These is almost the last part of step 2 in the associated bug.  There
may be some other small refactor work moving parts of initialization
code from gl_implementation_<platform>.cc to
gl_initializer_<platform>.cc necessary.

BUG=611142

Review-Url: https://codereview.chromium.org/2047283003
Cr-Commit-Position: refs/heads/master@{#399190}

[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/BUILD.gn
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl.gyp
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface.h
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_android.cc
[delete] https://crrev.com/5f0ab9c835e3f55e0d073239a75a4a73c1e61836/ui/gl/gl_surface_mac.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_osmesa.h
[add] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_osmesa_win.cc
[add] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_osmesa_win.h
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_ozone.cc
[add] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_ozone.h
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_wgl.h
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_win.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_x11.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/BUILD.gn
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/gl_factory.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/gl_factory_android.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/gl_factory_mac.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/gl_factory_ozone.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/gl_factory_win.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/gl_factory_x11.cc

Project Member Comment 7 by bugdroid1@chromium.org, Jun 15 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f1f2cba219ff4ee3071c716f7add731a5c9e39ca

commit f1f2cba219ff4ee3071c716f7add731a5c9e39ca
Author: kylechar <kylechar@chromium.org>
Date: Fri Jun 10 15:41:06 2016

Move GLSurface creation from //ui/gl to //ui/gl/init.

Move the code that performs GLSurface creation to the new target. Remove
old surface creation code and delete static methods from GLSurface.

Add InitializeGLSurface() function to simplify a common pattern. When a
new GLSurface is created, it is wrapped in a scoped_refptr and then
initialized. If initialization fails nullptr is returned instead.
Encapsulate this logic into a function instead of repeating it.

There are three Ozone related GLSurface subclasses that defined in an
anonymous namespace. Instead of moving the class definitions to a header
file, public functions are added to create these types, as the classes
need to be refactored heavily.

These is almost the last part of step 2 in the associated bug.  There
may be some other small refactor work moving parts of initialization
code from gl_implementation_<platform>.cc to
gl_initializer_<platform>.cc necessary.

BUG=611142

Review-Url: https://codereview.chromium.org/2047283003
Cr-Commit-Position: refs/heads/master@{#399190}

[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/BUILD.gn
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl.gyp
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface.h
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_android.cc
[delete] https://crrev.com/5f0ab9c835e3f55e0d073239a75a4a73c1e61836/ui/gl/gl_surface_mac.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_osmesa.h
[add] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_osmesa_win.cc
[add] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_osmesa_win.h
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_ozone.cc
[add] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_ozone.h
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_wgl.h
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_win.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/gl_surface_x11.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/BUILD.gn
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/gl_factory.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/gl_factory_android.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/gl_factory_mac.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/gl_factory_ozone.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/gl_factory_win.cc
[modify] https://crrev.com/f1f2cba219ff4ee3071c716f7add731a5c9e39ca/ui/gl/init/gl_factory_x11.cc

Project Member Comment 8 by bugdroid1@chromium.org, Jun 21 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9aeb4ff4c64befeafe6f0942921aafa989b6a90b

commit 9aeb4ff4c64befeafe6f0942921aafa989b6a90b
Author: kylechar <kylechar@chromium.org>
Date: Tue Jun 21 20:28:58 2016

Move GLSurface and rename source files.

Move the GLSurface implementations for Ozone from //ui/gl to
//ui/gl/init as part of breaking the dependency from //ui/gl on
//ui/ozone. These classes will later be refactored and moved back to
//ui/gl without any Ozone dependencies.

Also rename the files that contain the platform specific implementation
of GetPlatformDefaultEGLNativeDisplay() to be more appropriate.

BUG=611142

Review-Url: https://codereview.chromium.org/2088453003
Cr-Commit-Position: refs/heads/master@{#401093}

[modify] https://crrev.com/9aeb4ff4c64befeafe6f0942921aafa989b6a90b/ui/gl/BUILD.gn
[modify] https://crrev.com/9aeb4ff4c64befeafe6f0942921aafa989b6a90b/ui/gl/gl.gyp
[rename] https://crrev.com/9aeb4ff4c64befeafe6f0942921aafa989b6a90b/ui/gl/gl_surface_egl_android.cc
[add] https://crrev.com/9aeb4ff4c64befeafe6f0942921aafa989b6a90b/ui/gl/gl_surface_egl_ozone.cc
[rename] https://crrev.com/9aeb4ff4c64befeafe6f0942921aafa989b6a90b/ui/gl/gl_surface_egl_win.cc
[modify] https://crrev.com/9aeb4ff4c64befeafe6f0942921aafa989b6a90b/ui/gl/gl_surface_egl_x11.cc
[modify] https://crrev.com/9aeb4ff4c64befeafe6f0942921aafa989b6a90b/ui/gl/gl_surface_overlay.h
[delete] https://crrev.com/8e75cccd2ff5224bdd82662d47af49a26e247d39/ui/gl/gl_surface_ozone.h
[delete] https://crrev.com/8e75cccd2ff5224bdd82662d47af49a26e247d39/ui/gl/gl_surface_x11.cc
[modify] https://crrev.com/9aeb4ff4c64befeafe6f0942921aafa989b6a90b/ui/gl/init/BUILD.gn
[modify] https://crrev.com/9aeb4ff4c64befeafe6f0942921aafa989b6a90b/ui/gl/init/gl_factory_ozone.cc
[modify] https://crrev.com/9aeb4ff4c64befeafe6f0942921aafa989b6a90b/ui/gl/init/gl_init.gyp
[rename] https://crrev.com/9aeb4ff4c64befeafe6f0942921aafa989b6a90b/ui/gl/init/gl_surface_ozone.cc
[add] https://crrev.com/9aeb4ff4c64befeafe6f0942921aafa989b6a90b/ui/gl/init/gl_surface_ozone.h

Project Member Comment 9 by bugdroid1@chromium.org, Jun 27 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/507532e60d484704354edd17a7b51904e7a97d88

commit 507532e60d484704354edd17a7b51904e7a97d88
Author: kylechar <kylechar@chromium.org>
Date: Mon Jun 27 19:47:19 2016

Move static GL binding initialization to //ui/gl/init.

Static GL binding initialization needs to call out to the Ozone
platform. Move this initialization code from //ui/gl to //ui/gl/init as
part of larger effort to break //ui/gl dep on //ui/ozone. Also move
InitializationDebugGLBindings() and ClearGLBindings() in a similar
fashion as they are closely linked to static initialization.

Unfortunately, dynamic GL binding initialization can't be moved
//ui/gl/init. It would be nice to have all the initialization code in
one target but dynamic GL binding initialization is used by GLContext.

The existing InitializationStaticGLBindings() functions had grown to be
very large for some platforms. Where appropriate the code for each
implementation has been extracted into it's own method to improve
readability.

The PRESUBMIT.py script is modified slightly here. The existing static
GL initialization uses ScopedAllowIO on some platforms. This function is
banned so moving the code triggers presubmit errors. The GPU main thread
can't continue until initialization is finished anyways so moving
blocking code to a different thread isn't helpful. Add new exemptions to
PRESUBMIT.py.

BUG=611142
CQ_INCLUDE_TRYBOTS=tryserver.chromium.linux:linux_optional_gpu_tests_rel;tryserver.chromium.mac:mac_optional_gpu_tests_rel;tryserver.chromium.win:win_optional_gpu_tests_rel

Review-Url: https://codereview.chromium.org/2094513002
Cr-Commit-Position: refs/heads/master@{#402259}

[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/PRESUBMIT.py
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/gpu/command_buffer/service/gpu_service_test.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/gpu/config/gpu_info_collector_unittest.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/gpu/ipc/service/gpu_channel_unittest.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/angle_platform_impl.h
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gl_egl_api_implementation.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gl_egl_api_implementation.h
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gl_gl_api_implementation.h
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gl_glx_api_implementation.h
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gl_implementation.h
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gl_implementation_android.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gl_implementation_mac.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gl_implementation_osmesa.h
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gl_implementation_ozone.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gl_implementation_win.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gl_implementation_x11.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gl_osmesa_api_implementation.h
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gl_wgl_api_implementation.h
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/gpu_timing_unittest.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/init/gl_factory.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/init/gl_factory.h
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/init/gl_initializer.h
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/init/gl_initializer_android.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/init/gl_initializer_mac.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/init/gl_initializer_ozone.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/init/gl_initializer_win.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/init/gl_initializer_x11.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/test/gl_image_test_support.cc
[modify] https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88/ui/gl/test/gl_surface_test_support.cc

Project Member Comment 10 by bugdroid1@chromium.org, Jun 27 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f6fb94eabd50367cd9873ca6765fab04627f819b

commit f6fb94eabd50367cd9873ca6765fab04627f819b
Author: lambroslambrou <lambroslambrou@chromium.org>
Date: Mon Jun 27 21:21:53 2016

Revert of Move static GL binding initialization to //ui/gl/init. (patchset #7 id:120001 of https://codereview.chromium.org/2094513002/ )

Reason for revert:
Suspected of breaking Official "win trunk" builder:
c:\b\build\slave\win_trunk\build\src\ui\gl\init\gl_initializer_win.cc(32): fatal error C1083: Cannot open include file: 'software_renderer.h': No such file or directory
Please see crbug.com/623657 for details.

Original issue's description:
> Move static GL binding initialization to //ui/gl/init.
>
> Static GL binding initialization needs to call out to the Ozone
> platform. Move this initialization code from //ui/gl to //ui/gl/init as
> part of larger effort to break //ui/gl dep on //ui/ozone. Also move
> InitializationDebugGLBindings() and ClearGLBindings() in a similar
> fashion as they are closely linked to static initialization.
>
> Unfortunately, dynamic GL binding initialization can't be moved
> //ui/gl/init. It would be nice to have all the initialization code in
> one target but dynamic GL binding initialization is used by GLContext.
>
> The existing InitializationStaticGLBindings() functions had grown to be
> very large for some platforms. Where appropriate the code for each
> implementation has been extracted into it's own method to improve
> readability.
>
> The PRESUBMIT.py script is modified slightly here. The existing static
> GL initialization uses ScopedAllowIO on some platforms. This function is
> banned so moving the code triggers presubmit errors. The GPU main thread
> can't continue until initialization is finished anyways so moving
> blocking code to a different thread isn't helpful. Add new exemptions to
> PRESUBMIT.py.
>
> BUG=611142
> CQ_INCLUDE_TRYBOTS=tryserver.chromium.linux:linux_optional_gpu_tests_rel;tryserver.chromium.mac:mac_optional_gpu_tests_rel;tryserver.chromium.win:win_optional_gpu_tests_rel
>
> Committed: https://crrev.com/507532e60d484704354edd17a7b51904e7a97d88
> Cr-Commit-Position: refs/heads/master@{#402259}

TBR=piman@chromium.org,dpranke@chromium.org,kylechar@chromium.org
# Skipping CQ checks because original CL landed less than 1 days ago.
NOPRESUBMIT=true
NOTREECHECKS=true
NOTRY=true
BUG=611142

Review-Url: https://codereview.chromium.org/2099163003
Cr-Commit-Position: refs/heads/master@{#402287}

[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/PRESUBMIT.py
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/gpu/command_buffer/service/gpu_service_test.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/gpu/config/gpu_info_collector_unittest.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/gpu/ipc/service/gpu_channel_unittest.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/angle_platform_impl.h
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gl_egl_api_implementation.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gl_egl_api_implementation.h
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gl_gl_api_implementation.h
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gl_glx_api_implementation.h
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gl_implementation.h
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gl_implementation_android.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gl_implementation_mac.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gl_implementation_osmesa.h
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gl_implementation_ozone.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gl_implementation_win.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gl_implementation_x11.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gl_osmesa_api_implementation.h
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gl_wgl_api_implementation.h
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/gpu_timing_unittest.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/init/gl_factory.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/init/gl_factory.h
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/init/gl_initializer.h
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/init/gl_initializer_android.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/init/gl_initializer_mac.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/init/gl_initializer_ozone.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/init/gl_initializer_win.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/init/gl_initializer_x11.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/test/gl_image_test_support.cc
[modify] https://crrev.com/f6fb94eabd50367cd9873ca6765fab04627f819b/ui/gl/test/gl_surface_test_support.cc

Project Member Comment 11 by bugdroid1@chromium.org, Jul 4 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/166662417d4e35a04db2d9bd51e32da1d7119a12

commit 166662417d4e35a04db2d9bd51e32da1d7119a12
Author: kylechar <kylechar@chromium.org>
Date: Mon Jul 04 20:54:45 2016

Move static GL binding initialization to //ui/gl/init.

Static GL binding initialization needs to call out to the Ozone
platform. Move this initialization code from //ui/gl to //ui/gl/init as
part of larger effort to break //ui/gl dep on //ui/ozone. Also move
InitializationDebugGLBindings() and ClearGLBindings() in a similar
fashion as they are closely linked to static initialization.

Unfortunately, dynamic GL binding initialization can't be moved
//ui/gl/init. It would be nice to have all the initialization code in
one target but dynamic GL binding initialization is used by GLContext.

The existing InitializationStaticGLBindings() functions had grown to be
very large for some platforms. Where appropriate the code for each
implementation has been extracted into it's own method to improve
readability.

The PRESUBMIT.py script is modified slightly here. The existing static
GL initialization uses ScopedAllowIO on some platforms. This function is
banned so moving the code triggers presubmit errors. The GPU main thread
can't continue until initialization is finished anyways so moving
blocking code to a different thread isn't helpful. Add new exemptions to
PRESUBMIT.py.

This is a resubmission of r402259. The original patch was reverted after
it broke the win Chrome branded build. The include directory for
swiftshader was missing, this CL now modifies BUILD.gn and *.gyp files
appropriately.

BUG=611142
CQ_INCLUDE_TRYBOTS=tryserver.chromium.linux:linux_optional_gpu_tests_rel;tryserver.chromium.mac:mac_optional_gpu_tests_rel;tryserver.chromium.win:win_optional_gpu_tests_rel

Review-Url: https://codereview.chromium.org/2103123002
Cr-Commit-Position: refs/heads/master@{#403714}

[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/PRESUBMIT.py
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/gpu/command_buffer/service/gles2_cmd_decoder_unittest_base.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/gpu/command_buffer/service/gpu_service_test.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/gpu/config/gpu_info_collector_unittest.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/gpu/ipc/service/gpu_channel_unittest.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/BUILD.gn
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/angle_platform_impl.h
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl.gyp
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl_egl_api_implementation.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl_egl_api_implementation.h
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl_gl_api_implementation.h
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl_glx_api_implementation.h
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl_implementation.h
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl_implementation_android.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl_implementation_mac.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl_implementation_osmesa.h
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl_implementation_ozone.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl_implementation_win.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl_implementation_x11.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl_osmesa_api_implementation.h
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gl_wgl_api_implementation.h
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/gpu_timing_unittest.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/init/BUILD.gn
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/init/gl_factory.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/init/gl_factory.h
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/init/gl_init.gyp
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/init/gl_initializer.h
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/init/gl_initializer_android.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/init/gl_initializer_mac.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/init/gl_initializer_ozone.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/init/gl_initializer_win.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/init/gl_initializer_x11.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/test/gl_image_test_support.cc
[modify] https://crrev.com/166662417d4e35a04db2d9bd51e32da1d7119a12/ui/gl/test/gl_surface_test_support.cc

Project Member Comment 12 by bugdroid1@chromium.org, Jul 20 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/7dd36fe1e9bab00078cecd98616364ccf5e8b957

commit 7dd36fe1e9bab00078cecd98616364ccf5e8b957
Author: kylechar <kylechar@chromium.org>
Date: Wed Jul 20 19:44:06 2016

Remove GetPlatformDefaultEGLNativeDisplay() function.

During EGL initialization GetPlatformDefaultEGLNativeDisplay() gets
called. This function is conditionally compiled for each platform. Under
Ozone the function calls into OzonePlatform to get the EGL
native_display to use. This ordering requires that //ui/gl depends on
//ui/ozone which we want to break.

This CL removes GetPlatformDefaultEGLNativeDisplay() and instead passes
in the EGL native_display to GLSurfaceEGL::InitializeOneOff() or
GLSurfaceEGL::InitializeDisplay(). For tests EGL_DEFAULT_DISPLAY is
always passed in.

The GL initialization and autogen binding code needs to be rearranged to
accomplish this. For EGL generated code split the client extension
bindings and extension bindings into two separate methods. The client
extension bindings need to be initialized before
GLSurfaceEGL::InitializeDisplay() is called while the extension bindings
need to be initialized after. Also fix a problem preventing
generate_bindings.py from running with missing extension information due
to a recent change.

BUG=611142

Review-Url: https://codereview.chromium.org/2136553002
Cr-Commit-Position: refs/heads/master@{#406643}

[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/BUILD.gn
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/egl_api_unittest.cc
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/generate_bindings.py
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/gl.gyp
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/gl_bindings.cc
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/gl_bindings.h
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/gl_bindings_autogen_egl.cc
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/gl_egl_api_implementation.cc
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/gl_surface_egl.cc
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/gl_surface_egl.h
[delete] https://crrev.com/c9ed083cb0aefcbf4dde912343bb7c80f9e0fedc/ui/gl/gl_surface_egl_android.cc
[delete] https://crrev.com/c9ed083cb0aefcbf4dde912343bb7c80f9e0fedc/ui/gl/gl_surface_egl_ozone.cc
[delete] https://crrev.com/c9ed083cb0aefcbf4dde912343bb7c80f9e0fedc/ui/gl/gl_surface_egl_win.cc
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/gl_surface_egl_x11.cc
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/init/BUILD.gn
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/init/gl_init.gyp
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/init/gl_initializer_android.cc
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/init/gl_initializer_ozone.cc
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/init/gl_initializer_win.cc
[modify] https://crrev.com/7dd36fe1e9bab00078cecd98616364ccf5e8b957/ui/gl/init/gl_initializer_x11.cc

Project Member Comment 13 by bugdroid1@chromium.org, Jul 21 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/f63548fbd680e758624d51b9d330186442ecdc6c

commit f63548fbd680e758624d51b9d330186442ecdc6c
Author: kylechar <kylechar@chromium.org>
Date: Thu Jul 21 04:22:33 2016

Break //ui/gl/ dependency on //ui/ozone.

This CL removes the last code in //ui/gl that depends on //ui/ozone. It
then inverts the dependency so that //ui/ozone depends on //ui/gl and
each OzonePlatform can override GL specific classes.

GLImageOzoneNativePixmap is moved into a new target //ui/ozone/gl. This
is only possible now that the dependency problem has been fixed.

There is an issue with tests for GLImageOzoneNativePixmap. They are
still located in //ui/gl:gl_unittests as they depend on
//ui/gl:test_support. Moving the tests into //ui/ozone:ozone_unittests
has additional dependency problems. A new ozone_gl_unittests target
could be added in the future to avoid this but the remaining tests are
currently disabled anyways.

This is the finally CL in step 2 of the associated bug.

BUG=611142
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel

Review-Url: https://codereview.chromium.org/2102443003
Cr-Commit-Position: refs/heads/master@{#406765}

[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/gpu/gpu_ipc_service.gypi
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/gpu/ipc/service/gpu_memory_buffer_factory_ozone_native_pixmap.cc
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/media/gpu/vaapi_drm_picture.cc
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/media/media_gpu.gypi
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/services/ui/gles2/command_buffer_driver.cc
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/gl/BUILD.gn
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/gl/DEPS
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/gl/gl.gyp
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/gl/gl_image_ozone_native_pixmap_drm_unittest.cc
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/gl/gl_image_ozone_native_pixmap_unittest.cc
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/gl/gl_tests.gyp
[add] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/gl/init/DEPS
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/gl/init/gl_init.gyp
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/gl/init/gl_surface_ozone.cc
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/gl/test/DEPS
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/ozone/BUILD.gn
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/ozone/DEPS
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/ozone/demo/ozone_demos.gyp
[modify] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/ozone/demo/surfaceless_gl_renderer.cc
[add] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/ozone/gl/BUILD.gn
[rename] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/ozone/gl/gl_image_ozone_native_pixmap.cc
[rename] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/ozone/gl/gl_image_ozone_native_pixmap.h
[add] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/ozone/gl/ozone_gl.gyp
[add] https://crrev.com/f63548fbd680e758624d51b9d330186442ecdc6c/ui/ozone/gl/ozone_gl_export.h

Project Member Comment 14 by bugdroid1@chromium.org, Jul 21 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b598dffa8b18b1fbdc606e5db7c182ee5918ad84

commit b598dffa8b18b1fbdc606e5db7c182ee5918ad84
Author: kylechar <kylechar@chromium.org>
Date: Thu Jul 21 18:53:56 2016

Add new Ozone surface API.

This CL adds the new API for how ozone platforms will create GLSurfaces.
Now that //ui/ozone can depend on //ui/gl, the platform can create a
GLSurface directly. SurfaceFactoryOzone has methods added for creating
regular, surfaceless and offscreen surfaces. It also has a temporary
method that will allow us to switch platforms over one by one.

Small build file change to remove an unnecessary dep on //ui/base from
//ui/gl. Since it was in public_deps, a few downstream changes to
targets that depend on //ui/gl are needed as well.

This is the start of step 3 in the associated bug.

BUG=611142
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel

Review-Url: https://codereview.chromium.org/2122243002
Cr-Commit-Position: refs/heads/master@{#406922}

[modify] https://crrev.com/b598dffa8b18b1fbdc606e5db7c182ee5918ad84/gpu/ipc/client/BUILD.gn
[modify] https://crrev.com/b598dffa8b18b1fbdc606e5db7c182ee5918ad84/gpu/ipc/common/BUILD.gn
[modify] https://crrev.com/b598dffa8b18b1fbdc606e5db7c182ee5918ad84/gpu/ipc/service/BUILD.gn
[modify] https://crrev.com/b598dffa8b18b1fbdc606e5db7c182ee5918ad84/ui/gl/BUILD.gn
[modify] https://crrev.com/b598dffa8b18b1fbdc606e5db7c182ee5918ad84/ui/gl/DEPS
[modify] https://crrev.com/b598dffa8b18b1fbdc606e5db7c182ee5918ad84/ui/gl/gl.gyp
[modify] https://crrev.com/b598dffa8b18b1fbdc606e5db7c182ee5918ad84/ui/gl/gl_surface_egl.cc
[modify] https://crrev.com/b598dffa8b18b1fbdc606e5db7c182ee5918ad84/ui/ozone/BUILD.gn
[modify] https://crrev.com/b598dffa8b18b1fbdc606e5db7c182ee5918ad84/ui/ozone/ozone.gyp
[modify] https://crrev.com/b598dffa8b18b1fbdc606e5db7c182ee5918ad84/ui/ozone/public/surface_factory_ozone.cc
[modify] https://crrev.com/b598dffa8b18b1fbdc606e5db7c182ee5918ad84/ui/ozone/public/surface_factory_ozone.h

Project Member Comment 15 by bugdroid1@chromium.org, Jul 25 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/d6455ff601505aa6b111b087b3ee5af30a3cc385

commit d6455ff601505aa6b111b087b3ee5af30a3cc385
Author: kylechar <kylechar@chromium.org>
Date: Mon Jul 25 15:40:45 2016

Have Ozone X11 directly create GLSurfaces.

The Ozone X11 platform now directly creates an appropriate GLSurface
instead of creating a SurfaceOzoneEGL. Remove the SurfaceOzoneEGL
subclass and add a new GLSurface subclass.

Modify gl_factory_ozone.cc to use the new Ozone surface creation API.
For kGLImplementationOSMesaGL and kGLImplementationMockGL there is a
default implementation that is shared by all Ozone platforms. For other
GL implementations surface creation is delegated to the Ozone platform.

Add an OWNERS file for ui/gl/init/ that contains the per-file directive
for Ozone files from ui/gl/. This code was all moved from ui/gl/ since
it reduced the set of OWNERS. Add myself to this set as well.

BUG=611142

Review-Url: https://codereview.chromium.org/2156503003
Cr-Commit-Position: refs/heads/master@{#407485}

[add] https://crrev.com/d6455ff601505aa6b111b087b3ee5af30a3cc385/ui/gl/init/OWNERS
[modify] https://crrev.com/d6455ff601505aa6b111b087b3ee5af30a3cc385/ui/gl/init/gl_factory_ozone.cc
[modify] https://crrev.com/d6455ff601505aa6b111b087b3ee5af30a3cc385/ui/ozone/platform/x11/BUILD.gn
[modify] https://crrev.com/d6455ff601505aa6b111b087b3ee5af30a3cc385/ui/ozone/platform/x11/x11_surface_factory.cc
[modify] https://crrev.com/d6455ff601505aa6b111b087b3ee5af30a3cc385/ui/ozone/platform/x11/x11_surface_factory.h

Project Member Comment 16 by bugdroid1@chromium.org, Jul 25 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/b3d66d0ac16f7569abe9be477e5ac58e50ca2362

commit b3d66d0ac16f7569abe9be477e5ac58e50ca2362
Author: kylechar <kylechar@chromium.org>
Date: Mon Jul 25 21:16:10 2016

Convert Ozone GBM to use new surface API.

The Ozone GBM platform now directly creates GLSurfaces instead of
creating SurfaceOzoneEGL. The base classes for surfaceless and
framebuffer backed GLSurfaces is moved into //ui/ozone/platform/drm.
The old GbmSurfaceless class is replaced entirely despite retaining the
same name. A new GbmSurface class is added for the framebuffer backed
surface.

Add a new version of ChooseEGLConfig() to egl_util.cc/h that doesn't
rely on any callbacks now that deps problem as been fixed. The old
version will be deleted when this refactor is done as it will be unused.

BUG=611142

Review-Url: https://codereview.chromium.org/2165303002
Cr-Commit-Position: refs/heads/master@{#407574}

[modify] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/gl/init/gl_factory_ozone.cc
[modify] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/gl/init/gl_surface_ozone.cc
[modify] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/gl/init/gl_surface_ozone.h
[modify] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/ozone/common/BUILD.gn
[modify] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/ozone/common/egl_util.cc
[modify] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/ozone/common/egl_util.h
[modify] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/ozone/ozone.gyp
[modify] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/ozone/platform/drm/BUILD.gn
[modify] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/ozone/platform/drm/gbm.gypi
[add] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/ozone/platform/drm/gpu/gbm_surface.cc
[add] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/ozone/platform/drm/gpu/gbm_surface.h
[modify] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/ozone/platform/drm/gpu/gbm_surface_factory.cc
[modify] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/ozone/platform/drm/gpu/gbm_surface_factory.h
[modify] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/ozone/platform/drm/gpu/gbm_surfaceless.cc
[modify] https://crrev.com/b3d66d0ac16f7569abe9be477e5ac58e50ca2362/ui/ozone/platform/drm/gpu/gbm_surfaceless.h

Cc: j.iso...@samsung.com
Project Member Comment 18 by bugdroid1@chromium.org, Jul 27 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/93a53b3c9b7c6e52090f9fa08de2ef7e278114c0

commit 93a53b3c9b7c6e52090f9fa08de2ef7e278114c0
Author: kylechar <kylechar@chromium.org>
Date: Wed Jul 27 15:26:31 2016

Convert Ozone cast to directly create GLSurfaces.

The Ozone cast platform now directly creates an appropriate GLSurface
instead of creating a SurfaceOzoneEGL. Remove the SurfaceOzoneEGL
subclass and add a new GLSurface subclass.

BUG=611142

Review-Url: https://codereview.chromium.org/2179163003
Cr-Commit-Position: refs/heads/master@{#408133}

[modify] https://crrev.com/93a53b3c9b7c6e52090f9fa08de2ef7e278114c0/ui/ozone/platform/cast/BUILD.gn
[modify] https://crrev.com/93a53b3c9b7c6e52090f9fa08de2ef7e278114c0/ui/ozone/platform/cast/cast.gypi
[add] https://crrev.com/93a53b3c9b7c6e52090f9fa08de2ef7e278114c0/ui/ozone/platform/cast/gl_surface_cast.cc
[add] https://crrev.com/93a53b3c9b7c6e52090f9fa08de2ef7e278114c0/ui/ozone/platform/cast/gl_surface_cast.h
[modify] https://crrev.com/93a53b3c9b7c6e52090f9fa08de2ef7e278114c0/ui/ozone/platform/cast/surface_factory_cast.cc
[modify] https://crrev.com/93a53b3c9b7c6e52090f9fa08de2ef7e278114c0/ui/ozone/platform/cast/surface_factory_cast.h
[delete] https://crrev.com/c6f8b34b0708f8f3ca0b134e5a950d9709584e2f/ui/ozone/platform/cast/surface_ozone_egl_cast.cc
[delete] https://crrev.com/c6f8b34b0708f8f3ca0b134e5a950d9709584e2f/ui/ozone/platform/cast/surface_ozone_egl_cast.h

Project Member Comment 19 by bugdroid1@chromium.org, Jul 29 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/ee79ef399c3f4d2e3652981674eac9347e4b6a1a

commit ee79ef399c3f4d2e3652981674eac9347e4b6a1a
Author: kylechar <kylechar@chromium.org>
Date: Fri Jul 29 13:46:49 2016

Convert Ozone wayland to directly create GLSurfaces.

The Ozone wayland platform now directly creates an appropriate GLSurface
instead of creating a SurfaceOzoneEGL. Remove the SurfaceOzoneEGL
subclass and add a new GLSurface subclass.

BUG=611142

Review-Url: https://codereview.chromium.org/2187443003
Cr-Commit-Position: refs/heads/master@{#408631}

[modify] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/platform/wayland/BUILD.gn
[add] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/platform/wayland/gl_surface_wayland.cc
[add] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/platform/wayland/gl_surface_wayland.h
[modify] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/platform/wayland/wayland.gypi
[delete] https://crrev.com/589b2256f24ac204c3fdc17a333aebeac3eb7c07/ui/ozone/platform/wayland/wayland_egl_surface.cc
[delete] https://crrev.com/589b2256f24ac204c3fdc17a333aebeac3eb7c07/ui/ozone/platform/wayland/wayland_egl_surface.h
[modify] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/platform/wayland/wayland_surface_factory.cc
[modify] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/platform/wayland/wayland_surface_factory.h
[modify] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/public/surface_factory_ozone.cc

Project Member Comment 20 by bugdroid1@chromium.org, Jul 29 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/ee79ef399c3f4d2e3652981674eac9347e4b6a1a

commit ee79ef399c3f4d2e3652981674eac9347e4b6a1a
Author: kylechar <kylechar@chromium.org>
Date: Fri Jul 29 13:46:49 2016

Convert Ozone wayland to directly create GLSurfaces.

The Ozone wayland platform now directly creates an appropriate GLSurface
instead of creating a SurfaceOzoneEGL. Remove the SurfaceOzoneEGL
subclass and add a new GLSurface subclass.

BUG=611142

Review-Url: https://codereview.chromium.org/2187443003
Cr-Commit-Position: refs/heads/master@{#408631}

[modify] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/platform/wayland/BUILD.gn
[add] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/platform/wayland/gl_surface_wayland.cc
[add] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/platform/wayland/gl_surface_wayland.h
[modify] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/platform/wayland/wayland.gypi
[delete] https://crrev.com/589b2256f24ac204c3fdc17a333aebeac3eb7c07/ui/ozone/platform/wayland/wayland_egl_surface.cc
[delete] https://crrev.com/589b2256f24ac204c3fdc17a333aebeac3eb7c07/ui/ozone/platform/wayland/wayland_egl_surface.h
[modify] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/platform/wayland/wayland_surface_factory.cc
[modify] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/platform/wayland/wayland_surface_factory.h
[modify] https://crrev.com/ee79ef399c3f4d2e3652981674eac9347e4b6a1a/ui/ozone/public/surface_factory_ozone.cc

Project Member Comment 21 by bugdroid1@chromium.org, Aug 3 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/21dd510280003e6fa4b997237f0943ca4943ce99

commit 21dd510280003e6fa4b997237f0943ca4943ce99
Author: kylechar <kylechar@chromium.org>
Date: Wed Aug 03 19:41:11 2016

Move last of platform dependent init from //ui/gl to //ui/gl/init.

This CL moves the last two functions in gl_implementation_<platform>.cc
from //ui/gl to //ui/gl/init. These functions will need to be in
//ui/gl/init for Ozone to properly implement GLX. This also allows the
platform dependent gl_implementation_<platform>.cc files to be deleted.

BUG=611142
CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel

Review-Url: https://codereview.chromium.org/2189233003
Cr-Commit-Position: refs/heads/master@{#409594}

[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/gpu/config/gpu_info_collector.cc
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/BUILD.gn
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/gl.gyp
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/gl_egl_api_implementation.h
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/gl_glx_api_implementation.h
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/gl_implementation.h
[delete] https://crrev.com/aa76226ea00db9ce8f4db37596074ccabeca707c/ui/gl/gl_implementation_android.cc
[delete] https://crrev.com/aa76226ea00db9ce8f4db37596074ccabeca707c/ui/gl/gl_implementation_mac.cc
[delete] https://crrev.com/aa76226ea00db9ce8f4db37596074ccabeca707c/ui/gl/gl_implementation_ozone.cc
[delete] https://crrev.com/aa76226ea00db9ce8f4db37596074ccabeca707c/ui/gl/gl_implementation_win.cc
[delete] https://crrev.com/aa76226ea00db9ce8f4db37596074ccabeca707c/ui/gl/gl_implementation_x11.cc
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/gl_wgl_api_implementation.h
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/init/gl_factory.cc
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/init/gl_factory.h
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/init/gl_factory_android.cc
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/init/gl_factory_mac.cc
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/init/gl_factory_ozone.cc
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/init/gl_factory_win.cc
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/init/gl_factory_x11.cc
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/test/gl_image_test_support.cc
[modify] https://crrev.com/21dd510280003e6fa4b997237f0943ca4943ce99/ui/gl/test/gl_surface_test_support.cc

Project Member Comment 22 by bugdroid1@chromium.org, Aug 4 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/01a32f17f8bf3ddf8c2a523ea30a44ba21418453

commit 01a32f17f8bf3ddf8c2a523ea30a44ba21418453
Author: kylechar <kylechar@chromium.org>
Date: Thu Aug 04 19:46:48 2016

Delete old Ozone surface creation API.

This CL deletes the remainder of the old Ozone surface API. All Ozone
platforms have been switched over to the new API and directly create
GLSurfaces.

Remove SurfaceOzoneEGL, GLSurfaceOzoneEGL and some helper methods. The
SwapCompletionCallback typedef from SurfaceOzoneEGL is moved to it's own
file so it can still be used.

This essentially finishes the refactor in the associated bug.

BUG=611142

Review-Url: https://codereview.chromium.org/2190353003
Cr-Commit-Position: refs/heads/master@{#409872}

[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/gl/init/BUILD.gn
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/gl/init/gl_factory_ozone.cc
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/gl/init/gl_init.gyp
[delete] https://crrev.com/faa7234dcd0a10e53dd9313869a9aace6d651af1/ui/gl/init/gl_surface_ozone.cc
[delete] https://crrev.com/faa7234dcd0a10e53dd9313869a9aace6d651af1/ui/gl/init/gl_surface_ozone.h
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/BUILD.gn
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/common/egl_util.cc
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/common/egl_util.h
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/ozone.gyp
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/platform/cast/surface_factory_cast.cc
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/platform/cast/surface_factory_cast.h
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/platform/drm/gpu/drm_thread.h
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/platform/drm/gpu/drm_window.h
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/platform/drm/gpu/drm_window_proxy.h
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/platform/drm/gpu/gbm_surface_factory.cc
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/platform/drm/gpu/gbm_surface_factory.h
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/platform/drm/gpu/page_flip_request.h
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/platform/wayland/wayland_surface_factory.cc
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/platform/x11/x11_surface_factory.cc
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/platform/x11/x11_surface_factory.h
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/public/surface_factory_ozone.cc
[modify] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/public/surface_factory_ozone.h
[delete] https://crrev.com/faa7234dcd0a10e53dd9313869a9aace6d651af1/ui/ozone/public/surface_ozone_egl.cc
[delete] https://crrev.com/faa7234dcd0a10e53dd9313869a9aace6d651af1/ui/ozone/public/surface_ozone_egl.h
[add] https://crrev.com/01a32f17f8bf3ddf8c2a523ea30a44ba21418453/ui/ozone/public/swap_completion_callback.h

Status: Fixed
Project Member Comment 24 by bugdroid1@chromium.org, Aug 18 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/ef99f26bfbb364be711a0c7ddf301df1951277ec

commit ef99f26bfbb364be711a0c7ddf301df1951277ec
Author: kylechar <kylechar@chromium.org>
Date: Thu Aug 18 21:22:38 2016

Remove callbacks for SurfaceFactoryOzone::LoadEGLGLES2Bindings().

Functions defined in //ui/gl originally had to be provided as callbacks
due to dependency problems. This is no longer necessary, so switch Ozone
implementations to call functions directly.

BUG=611142

Review-Url: https://codereview.chromium.org/2253173002
Cr-Commit-Position: refs/heads/master@{#412931}

[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/gl/init/gl_initializer_ozone.cc
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/common/egl_util.cc
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/common/egl_util.h
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/platform/caca/caca_window_manager.cc
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/platform/caca/caca_window_manager.h
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/platform/cast/surface_factory_cast.cc
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/platform/cast/surface_factory_cast.h
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/platform/drm/gpu/gbm_surface_factory.cc
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/platform/drm/gpu/gbm_surface_factory.h
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/platform/headless/headless_surface_factory.cc
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/platform/headless/headless_surface_factory.h
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/platform/wayland/wayland_surface_factory.cc
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/platform/wayland/wayland_surface_factory.h
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/platform/x11/x11_surface_factory.cc
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/platform/x11/x11_surface_factory.h
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/public/surface_factory_ozone.cc
[modify] https://crrev.com/ef99f26bfbb364be711a0c7ddf301df1951277ec/ui/ozone/public/surface_factory_ozone.h

Status: Started
Project Member Comment 26 by bugdroid1@chromium.org, Aug 24 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/4fab9214930cb13623ecd24aea0381e07c1a333c

commit 4fab9214930cb13623ecd24aea0381e07c1a333c
Author: kylechar <kylechar@chromium.org>
Date: Wed Aug 24 21:09:10 2016

Move GLImageOzoneNativePixmap tests to src/ui/ozone.

GLImageOzoneNativePixmap was previously moved from //ui/gl to
//ui/ozone/gl. The related tests were not moved at the same time. This
CL moves the tests to a new target //ui/ozone/gl:ozone_gl_unittests.

The exists ozone_unittests target does not have an appropriate TestSuite
for running GL tests, so a different target is required. The existing
TestSuite for GL tests is placed in a source_set so it can be used by
both gl_unittests and ozone_gl_unittests.

Add the new ozone_gl_unittests target to the Ozone Chrome OS trybot.
Finally, remove some unneeded DEPS rules now that the tests have been
moved.

BUG=611142

Review-Url: https://codereview.chromium.org/2254303002
Cr-Commit-Position: refs/heads/master@{#414145}

[modify] https://crrev.com/4fab9214930cb13623ecd24aea0381e07c1a333c/testing/buildbot/chromium.chromiumos.json
[modify] https://crrev.com/4fab9214930cb13623ecd24aea0381e07c1a333c/testing/buildbot/gn_isolate_map.pyl
[modify] https://crrev.com/4fab9214930cb13623ecd24aea0381e07c1a333c/ui/gl/BUILD.gn
[modify] https://crrev.com/4fab9214930cb13623ecd24aea0381e07c1a333c/ui/gl/DEPS
[modify] https://crrev.com/4fab9214930cb13623ecd24aea0381e07c1a333c/ui/gl/test/run_all_unittests.cc
[modify] https://crrev.com/4fab9214930cb13623ecd24aea0381e07c1a333c/ui/ozone/gl/BUILD.gn
[rename] https://crrev.com/4fab9214930cb13623ecd24aea0381e07c1a333c/ui/ozone/gl/gl_image_ozone_native_pixmap_drm_unittest.cc
[rename] https://crrev.com/4fab9214930cb13623ecd24aea0381e07c1a333c/ui/ozone/gl/gl_image_ozone_native_pixmap_unittest.cc

Status: Fixed
Blockedon: 650284
Project Member Comment 29 by bugdroid1@chromium.org, Oct 3 2016
The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/903932cf3bcfa9a0eb58b3660c9bad83c4c7e3d3

commit 903932cf3bcfa9a0eb58b3660c9bad83c4c7e3d3
Author: tonikitoo <tonikitoo@igalia.com>
Date: Mon Oct 03 18:52:31 2016

Use SurfacelessEGL for ozone/wayland, when supported

Since [1], chrome --mash --ozone-platform=wayland fails to
launch in some systems, where the call to
PbufferGLSurfaceEGL::Initialize (ui/gl/gl_surface_egl.cc) fails
at

  EGLSurface new_surface =
      eglCreatePbufferSurface(display, GetConfig(), &pbuffer_attribs[0]);

... because GetConfig does not return a valid EGLConfig instance.

As per @kylechar's advice, this CL opt-in for a SufacelessEGL
creation, if supported, rather than PbufferGLSurfaceEGL, similarly
to how it was prior to [1].

[1] https://codereview.chromium.org/2187443003

BUG=650284,611142

Review-Url: https://codereview.chromium.org/2387063002
Cr-Commit-Position: refs/heads/master@{#422475}

[modify] https://crrev.com/903932cf3bcfa9a0eb58b3660c9bad83c4c7e3d3/ui/ozone/platform/wayland/wayland_surface_factory.cc

Sign in to add a comment