|
| 1 | +diff -ruN cobalt.orig/src/cobalt/renderer/backend/egl/graphics_context.cc cobalt/src/cobalt/renderer/backend/egl/graphics_context.cc |
| 2 | +--- cobalt.orig/src/cobalt/renderer/backend/egl/graphics_context.cc 2021-05-27 17:36:48.000000000 +0530 |
| 3 | ++++ cobalt/src/cobalt/renderer/backend/egl/graphics_context.cc 2021-07-05 22:36:14.143943715 +0530 |
| 4 | +@@ -76,7 +76,7 @@ |
| 5 | + // when we need to make OpenGL calls that do not depend on a surface (e.g. |
| 6 | + // creating a texture). |
| 7 | + null_surface_ = new PBufferRenderTargetEGL(display, config, math::Size(0, 0)); |
| 8 | +- CHECK(!null_surface_->CreationError()); |
| 9 | ++ // CHECK(!null_surface_->CreationError()); |
| 10 | + |
| 11 | + ScopedMakeCurrent scoped_current_context(this); |
| 12 | + |
| 13 | +diff -ruN cobalt.orig/src/cobalt/renderer/backend/egl/graphics_system.cc cobalt/src/cobalt/renderer/backend/egl/graphics_system.cc |
| 14 | +--- cobalt.orig/src/cobalt/renderer/backend/egl/graphics_system.cc 2021-05-27 17:36:48.000000000 +0530 |
| 15 | ++++ cobalt/src/cobalt/renderer/backend/egl/graphics_system.cc 2021-07-05 22:36:39.544296168 +0530 |
| 16 | +@@ -105,7 +105,10 @@ |
| 17 | + // Return the first config that succeeds the above test. |
| 18 | + EGLint num_configs = 0; |
| 19 | + EGL_CALL(eglChooseConfig(display, attribute_list, NULL, 0, &num_configs)); |
| 20 | +- CHECK_LT(0, num_configs); |
| 21 | ++ // CHECK_LT(0, num_configs); |
| 22 | ++ if (!num_configs) { |
| 23 | ++ return base::nullopt; |
| 24 | ++ } |
| 25 | + |
| 26 | + std::unique_ptr<EGLConfig[]> configs(new EGLConfig[num_configs]); |
| 27 | + EGL_CALL_SIMPLE(eglChooseConfig(display, attribute_list, configs.get(), |
| 28 | +@@ -201,6 +204,15 @@ |
| 29 | + } |
| 30 | + } |
| 31 | + |
| 32 | ++ if (!choose_config_results) { |
| 33 | ++ DCHECK_EQ(EGL_SURFACE_TYPE, attribute_list[0]); |
| 34 | ++ EGLint& surface_type_value = attribute_list[1]; |
| 35 | ++ |
| 36 | ++ surface_type_value &= ~EGL_PBUFFER_BIT; |
| 37 | ++ choose_config_results = |
| 38 | ++ ChooseConfig(display_, attribute_list, system_window); |
| 39 | ++ } |
| 40 | ++ |
| 41 | + DCHECK(choose_config_results); |
| 42 | + |
| 43 | + config_ = choose_config_results->config; |
| 44 | +diff -ruN cobalt.orig/src/third_party/starboard/wpe/rpi/gyp_configuration.gypi cobalt/src/third_party/starboard/wpe/rpi/gyp_configuration.gypi |
| 45 | +--- cobalt.orig/src/third_party/starboard/wpe/rpi/gyp_configuration.gypi 2021-07-05 22:30:34.734565943 +0530 |
| 46 | ++++ cobalt/src/third_party/starboard/wpe/rpi/gyp_configuration.gypi 2021-07-05 22:40:01.850929559 +0530 |
| 47 | +@@ -50,6 +50,7 @@ |
| 48 | + |
| 49 | + # To support large files |
| 50 | + '-D_FILE_OFFSET_BITS=64', |
| 51 | ++ '-DEGL_NO_X11', |
| 52 | + |
| 53 | + # Suppress some warnings that will be hard to fix. |
| 54 | + '-Wno-unused-local-typedefs', |
| 55 | +diff -ruN cobalt.orig/src/third_party/starboard/wpe/shared/window/window_internal.h cobalt/src/third_party/starboard/wpe/shared/window/window_internal.h |
| 56 | +--- cobalt.orig/src/third_party/starboard/wpe/shared/window/window_internal.h 2021-05-27 17:36:48.000000000 +0530 |
| 57 | ++++ cobalt/src/third_party/starboard/wpe/shared/window/window_internal.h 2021-07-05 22:37:46.997216291 +0530 |
| 58 | +@@ -20,7 +20,6 @@ |
| 59 | + #include "starboard/time.h" |
| 60 | + #include "starboard/window.h" |
| 61 | + |
| 62 | +-#define EGL_NO_X11 |
| 63 | + #include "WPEFramework/compositor/Client.h" |
| 64 | + |
| 65 | + namespace third_party { |
0 commit comments