This is part of efforts bringing ANGLE support for WebGL to gtk port.
Created attachment 384034 [details] Patch
Created attachment 384035 [details] Patch
Comment on attachment 384035 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=384035&action=review > Source/WebKit/UIProcess/gtk/AcceleratedBackingStoreWayland.cpp:84 > + if (!availableExtensions.contains("GL_ARB_texture_storage"_s)) { > + GLint majorVersion; > + ::glGetIntegerv(GL_MAJOR_VERSION, &majorVersion); > + GLint minorVersion; > + ::glGetIntegerv(GL_MINOR_VERSION, &minorVersion); > + if (majorVersion > 4 || (majorVersion == 4 && minorVersion >= 2)) > + availableExtensions.add("GL_ARB_texture_storage"_s); > + } We can simply this, since are only interested in GL_OES_EGL_image and glEGLImageTargetTexture2DOES we don't need to handle this exception here for GL_ARB_texture_storage. > Source/WebKit/UIProcess/gtk/AcceleratedBackingStoreWayland.cpp:115 > + if (availableExtensions.contains("GL_OES_EGL_image") || availableExtensions.contains("GL_OES_EGL_image_external")) If we are going to build the list of extensions here, we can simplify this even more. Let's just add checkEGLImageAvailable (or something like that) and check any of those are available using the gl api directly, instead of first building a has set to then check if any of those are present.
Created attachment 384234 [details] Patch
Comment on attachment 384035 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=384035&action=review >> Source/WebKit/UIProcess/gtk/AcceleratedBackingStoreWayland.cpp:84 >> + } > > We can simply this, since are only interested in GL_OES_EGL_image and glEGLImageTargetTexture2DOES we don't need to handle this exception here for GL_ARB_texture_storage. You're right. >> Source/WebKit/UIProcess/gtk/AcceleratedBackingStoreWayland.cpp:115 >> + if (availableExtensions.contains("GL_OES_EGL_image") || availableExtensions.contains("GL_OES_EGL_image_external")) > > If we are going to build the list of extensions here, we can simplify this even more. Let's just add checkEGLImageAvailable (or something like that) and check any of those are available using the gl api directly, instead of first building a has set to then check if any of those are present. That is a good suggestion. Thanks!
Comment on attachment 384234 [details] Patch Clearing flags on attachment: 384234 Committed r252851: <https://trac.webkit.org/changeset/252851>
All reviewed patches have been landed. Closing bug.