diff --git a/shell/common/shell_io_manager.cc b/shell/common/shell_io_manager.cc index ec22661b3763d..59de967e1cc0f 100644 --- a/shell/common/shell_io_manager.cc +++ b/shell/common/shell_io_manager.cc @@ -10,14 +10,15 @@ #include "flutter/shell/common/context_options.h" #include "third_party/skia/include/gpu/ganesh/gl/GrGLDirectContext.h" #include "third_party/skia/include/gpu/gl/GrGLInterface.h" +#include "third_party/skia/include/gpu/gl/GrGLTypes.h" namespace flutter { sk_sp ShellIOManager::CreateCompatibleResourceLoadingContext( - GrBackend backend, + GrBackendApi backend, const sk_sp& gl_interface) { #if SK_GL - if (backend != GrBackend::kOpenGL_GrBackend) { + if (backend != GrBackendApi::kOpenGL) { return nullptr; } diff --git a/shell/common/shell_io_manager.h b/shell/common/shell_io_manager.h index b178541939771..9c105a80d174c 100644 --- a/shell/common/shell_io_manager.h +++ b/shell/common/shell_io_manager.h @@ -12,6 +12,9 @@ #include "flutter/fml/memory/weak_ptr.h" #include "flutter/lib/ui/io_manager.h" #include "third_party/skia/include/gpu/GrDirectContext.h" +#include "third_party/skia/include/gpu/GrTypes.h" + +struct GrGLInterface; namespace flutter { @@ -21,7 +24,7 @@ class ShellIOManager final : public IOManager { // supply to the IOManager. The platforms may create the context themselves if // they so desire. static sk_sp CreateCompatibleResourceLoadingContext( - GrBackend backend, + GrBackendApi backend, const sk_sp& gl_interface); ShellIOManager( diff --git a/shell/platform/android/platform_view_android.cc b/shell/platform/android/platform_view_android.cc index 83f1f635cf639..485f00eb189e8 100644 --- a/shell/platform/android/platform_view_android.cc +++ b/shell/platform/android/platform_view_android.cc @@ -386,7 +386,7 @@ sk_sp PlatformViewAndroid::CreateResourceContext() const { // the OpenGL surface will be able to make a resource context current. If // this changes, this assumption breaks. Handle the same. resource_context = ShellIOManager::CreateCompatibleResourceLoadingContext( - GrBackend::kOpenGL_GrBackend, + GrBackendApi::kOpenGL, GPUSurfaceGLDelegate::GetDefaultPlatformGLInterface()); } else { FML_DLOG(ERROR) << "Could not make the resource context current."; diff --git a/shell/platform/embedder/embedder_surface_gl.cc b/shell/platform/embedder/embedder_surface_gl.cc index 44b1fddf808fb..cd32348e10306 100644 --- a/shell/platform/embedder/embedder_surface_gl.cc +++ b/shell/platform/embedder/embedder_surface_gl.cc @@ -107,7 +107,7 @@ sk_sp EmbedderSurfaceGL::CreateResourceContext() const { auto callback = gl_dispatch_table_.gl_make_resource_current_callback; if (callback && callback()) { if (auto context = ShellIOManager::CreateCompatibleResourceLoadingContext( - GrBackend::kOpenGL_GrBackend, GetGLInterface())) { + GrBackendApi::kOpenGL, GetGLInterface())) { return context; } else { FML_LOG(ERROR)