graesslin created this revision. graesslin added reviewers: KWin, Plasma on Wayland. Restricted Application added subscribers: kwin, plasma-devel. Restricted Application added projects: Plasma on Wayland, KWin.
REVISION SUMMARY KWin still resolves some OpenGL function pointers. For that it needs to use either eglGetProcAddress or glxGetProcAddress. With other words the method to resolve needs to know whether it is egl or glx and needs both a dependency to egl and glx. Especially the dependency to glx is ugly as that pulls in XLib into our library. The way so far was to pass an enum value to the initGL method to know whether it's EGL or GLX. With this change the enum value is removed and replaced by a function pointer to resolve the methods. This simplifies the resolve code and allows to completely remove the glx variant we still had in the library. Thus kwinglutils library is now glx and XLib free. TEST PLAN nested KWin with OpenGL/EGL still works REPOSITORY rKWIN KWin BRANCH initgl-with-resolve-function REVISION DETAIL https://phabricator.kde.org/D3336 AFFECTED FILES abstract_egl_backend.cpp libkwineffects/CMakeLists.txt libkwineffects/kwinglutils.cpp libkwineffects/kwinglutils.h libkwineffects/kwinglutils_funcs.cpp libkwineffects/kwinglutils_funcs.h plugins/platforms/x11/standalone/glxbackend.cpp EMAIL PREFERENCES https://phabricator.kde.org/settings/panel/emailpreferences/ To: graesslin, #kwin, #plasma_on_wayland Cc: plasma-devel, kwin, lesliezhai, ali-mohamed, hardening, jensreuterberg, abetts, sebas