-
-
Notifications
You must be signed in to change notification settings - Fork 55.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Explicitly prefer legacy GL in cmake on Linux? #22836
base: 4.x
Are you sure you want to change the base?
Conversation
I am not so sure about that choice anymore. Because I made more research on #22704 and found the following statement "It allows EGL and GLX to coexist in the same process." here: https://www.x.org/wiki/Events/XDC2017/brenneman_GLVND.pdf Also, at least on my system all the binaries that link EGL and GLX also link libGLdispatch as well. Including the opencv that is shipped with OpenSuse. Need to do more research and tests. |
I did some experiments using GLVND. Including running a program using CL/GL (through EGL), CL/VA and highgui (imshow based on QT - with and without OpenGL). I'd also like to stress any code that uses the Anyway I couldn't find any problems yet. In legacy mode (with EGL patch enabled) the following libraries are linked to the OpenCV core so:
In GLVND mode (with EGL patch enabled) the following libraries are linked to the OpenCV core so:
So in both cases GLX, EGL and libGLdispatch are linked but in GLVND mode the old libGL isn't. So actually GLVND looks like the safer and better choice to me since it removes a dependency that has been deprecated since 2008. |
Btw. because it has been abstracted well, replacing GLX based function pointer loading for Linux could easily be replaced with an EGL call. opencv/modules/core/src/gl_core_3_1.cpp Lines 131 to 133 in 6ca205a
|
From this point i will document the progress on GLVND+EGL in PR #22704 because I have come to the conclusion that those decisions are linked and I want a single point of information. |
Pertaining Issue: #22835
Pull Request Readiness Checklist
See details at https://github.com/opencv/opencv/wiki/How_to_contribute#making-a-good-pull-request
Patch to opencv_extra has the same branch name.