PDA

View Full Version : glx or egl



_jesse_
01-21-2013, 07:10 AM
I heard that glx will be deprecated and replaced by egl. Is that true?

I have asked this question on khronos forum, but no one answer me.

Sometimes I write OpenGL on Windows, but most of the time I write OpenGL on FreeBSD. But FreeBSD is not Linux. I am sorry to post it here.

Alfonse Reinheart
01-21-2013, 11:31 AM
Will it be? Maybe. But not anytime soon. Khronos has announced no initiative towards this goal.

_jesse_
01-21-2013, 07:32 PM
That will be a little sad. I don't know how to start egl on X, Could you give me some clues?

Alfonse Reinheart
01-21-2013, 07:50 PM
You don't. That's what I just said; there is no EGL on X.

_jesse_
01-21-2013, 10:37 PM
Thank you!

thokra
01-22-2013, 01:15 AM
You don't. That's what I just said; there is no EGL on X.

That is not exactly true. AFAIK, it may still be true talking about proprietary drivers and it may very well be true with the X version current FreeBSD versions provide, but it's not true for any X based OS in general. Mesa (http://www.mesa3d.org/egl.html) implements everything you need to setup a context using EGL and there are projects that actually do it. For instance, KDE's KWin supports EGL context creation while still using GL2 afterwards (not GLES2). The main KWin dev elaborates in his blog (http://blog.martin-graesslin.com/blog/2012/09/who-needs-glx-kwin-does-not/). In addition, there is a proposal to deprecate GLX on Linux so EGL should eventually be your goto solution. For an additional scoop you may refer to groovounet's blog (http://www.g-truc.net/post-0457.html). Although I don't think it's anywhere near being a good resource, Phoronix has also "reported" on several occasions about EGL being actively used in Linux (and thus X based) environments.

Incidentally, after Wayland has been adopted, and I'm sure it will be at some point, EGL will be everything you need if AMD and NVIDIA catch up.

mbentrup
01-22-2013, 02:42 AM
There was also a talk about this on the XDC 2012, you can find it on YouTube.

thokra
01-22-2013, 02:51 AM
Yep, this is where Intel's Ian Romanick suggested GLX deprecration.

Alfonse Reinheart
01-22-2013, 04:32 PM
Good thing OpenGL has a good track record with deprecation.

thokra
01-22-2013, 04:44 PM
Maybe they've learned their lesson by now. ;-)

nigels
01-23-2013, 12:54 PM
I've seen X11+EGL+ES 2.0 on L4T (Linux for Tegra).
https://developer.nvidia.com/linux-tegra

- Nigel

kRogue
01-25-2013, 02:17 PM
You don't. That's what I just said; there is no EGL on X.


That is down right false. There are platforms that use X11 and use EGL (for example N9, N900, Maemo, MeeGo, etc). Ubuntu on Tegra is X11 with EGL. These same platforms do NOT have glx.

Though in all honesty, EGL really does not buy you anything; it just means different startup kludge code to create a GL context, etc. The specification is more focused on GLES1/2/3 than desktop GL. Indeed, although EGL has a mechanism to create a GL context, it lacks all of the goodies found in wgl/glxCreateContexAttribsARB.

mbentrup
01-26-2013, 02:18 AM
Indeed, although EGL has a mechanism to create a GL context, it lacks all of the goodies found in wgl/glxCreateContexAttribsARB.

You should take a look at EGL_KHR_create_context, I think it covers everything glx can do.

kRogue
01-26-2013, 06:37 AM
Indeed it does.

nigels
01-30-2013, 08:06 AM
There is also Mesa EGL/ES2 on X11 Ubuntu 12.04, that I've seen in action.
Which seems handy for cross-developing for Android, etc.
Just recently I noticed that freeglut now supports EGL/ES2 as an alternative to GLX or WGL.

- Nigel

_jesse_
02-03-2013, 11:40 AM
i have built out the demodriver.so of mesa egl on freebsd, but i failed to create the egl context.

techzilla
02-09-2013, 11:21 AM
GLX is very X11 specific, so transitioning towards EGL brings significant benefits. I don't see why someone couldn't create a GLX over EGL wrapper, to help run legacy code on platforms without GLX. The main reason why EGL has become necessary, is to disconnect X11 from OpenGL. So it opens a multitude of use cases for OpenGL, or at least vastly simplifies their implantation..... To put this another way, EGL is no pulseaudio.

_jesse_
02-11-2013, 01:04 PM
i think it is not hurry to use egl as it has not a mature implementation. glx is still a better choice to use accelerated gpu.