If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.

EGL implementation for Window and Linux

I'm looking to use EGL to do headless rendering to a framebuffer in both Linux and Windows. The ultimate goal is to develop a program that will run on the Amazon cloud where it will have access to an NVIDIA GPU, but not necessarily a windowing system. The output would be sent out in a video stream. I would also like to be able to run the same code in Windows as well. I guess technically it doesn't have to be a cross-platform implementation, as long as the Linux and Windows implementations are both EGL compliant.

I'm looking for an EGL implementation(s) to help me do this, but am having a hard time. What I have found:

The Khronos website lists an implementation called Pablo, but the link is dead. I couldn't find any more information about this.

McNopper has an implementation on github, but it looks incomplete with the caveat that is in the early stage and not well tested.

Various OpenGL ES emulators seem to implement EGL, such as ARM, Imagination Tech, Qualcomm, and Angles. But I think I want a native solution, not an emulation.

On Linux, Mesa libraries support EGL. It's unclear to me if this is a software only solution, meaning that it doesn't actually use the GPU.

On Windows, GLFW can do a hidden window, but this isn't exactly the same.

I've seen plenty of example code on how to right an EGL application, but I can't find the actual EGL implementation. Can someone help a confused person?

You will need to look at the AWS OpenGL API. A OpenGL implementation must be paired with a EGL/WGL/CGL/GLX or similar API that creates the contexts that OpenGL uses for rendering. You can't just provide your own. EGL hooks into the internals of OpenGL to create Contexts, DefaultFramebuffers, Fences, and such. It also hooks into the platform window system to put your content into a window. I did a quick look at AWS and didn't see it immediately.
Second, you will need to get the rendered buffers out of OpenGL. glReadPixels is the only common function. There is EGL_KHR_lock_surface - but this extension is not commonly implemented in all implementations. There may be "native" images that can create EGLImage that then can be used as a texture to a FBO. Here you have direct access to the buffer. But this is not common across platforms.
Finally, your rendered content/buffer has to be formatted for video stream. Again, the render to YUV format is an extension, so may not be common to all the platforms you want.
Interesting project, but you are trying to use OpenGL in non-common way, hence the barriers. First look into AWS to see what it provides to access the rendered buffers.
If you find a link to AWS EGL features, then I might be able to make suggestions. I'll look if I get time.

Thanks for the replies, I've been looking into this more. It does look like Linux is covered with NVidia's drivers, and perhaps AWS too. But I haven't found anything for Windows, does such an implementation exist?