Commit Graph

3 Commits

Author SHA1 Message Date
Yuxuan Shui eb723eee29
backend: gl: use libepoxy
There is actually no specification what symbols are exported from a
libGL implementation. The (extremely outdated) OpenGL ABI specification
says only GL 1.2 functions are guaranteed. Don't know how relevant that
is now, but different libGL implementations do export different set of
symbols. On Linux we are most likely to be linked with libglvnd, which
has everything we need. But on other platforms this is not necessarily
the case, for example on OpenBSD we are missing glGetQueryObjectui64v.

Use libepoxy so we can outsource this problem and never worry about it
ever again. Plus it also saves us from calling GetProcAddress ourselves.

Changes other than trivial build fixes I have to make:

1. Can't use eglCreatePlatformWindowSurface/eglGetPlatformDisplay.
   libepoxy checks for EGL 1.5 when resolving these functions. But
   without a current context, libepoxy assumes we only have EGL 1.4.
   This creates a chicken and egg problem - we need a display to call
   eglGetPlatformDisplay. We have to use the *EXT version instead.

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
2024-02-10 20:36:02 +00:00
Maxim Solovyov 689321419b
backend: egl: remove references to the glx backend 2023-06-18 19:30:01 +03:00
Yuxuan Shui 5a72b5755d
backends: add egl backend
This needs the EGL_KHR_image_pixmap and the GL_EXT_EGL_image_storage
extensions, which unfortunately aren't available on NVIDIA cards.

Don't add documentation for these, for now.

Signed-off-by: Yuxuan Shui <yshuiv7@gmail.com>
2022-09-29 08:03:12 +01:00