Uh oh!
There was an error while loading. Please reload this page.
fix(linux): initialize EGL via GLAD correctly - #4852
Conversation
psyke83
commented
Mar 15, 2026
Tested and confirmed working against kmsgrab and portalgrab backends, and creates the EGL context successfully from ssh as well. It should work on nvidia based on cursory search online, e.g.: https://docs.nvidia.com/drive/drive-os-5.2.0.0L/drive-os/index.html#page/DRIVE_OS_Linux_SDK_Development_Guide/Windows%20Systems/window_system_egl.html ...but it might be a good idea for a nvidia user to test to be sure. |
ab6e286 to
631d64dCompare* misc.cpp: phase 1 load (symbols only, defaults to EGL 1.0). * graphics.cpp: phase 2 load using correct display configuration with eglGetPlatformDisplayEXT (initializes proper EGL version dispatch). * Retain eglGetPlatformDisplay fallback if proprietary drivers need it. * Add missing/required extensions to GLAD makefile based on existing extensions queried & new eglGetPlatformDisplayEXT requirement. * Remove hardcoded definitions that are part of previously missing extensions.
psyke83
commented
Mar 15, 2026
After looking at the glad sources, another optimization that could be applied that might improve VAAPI encoding (and anything else that relies on EGL; Vulkan doesn't apply). I'll send a separate PR after you've merged this branch, but this is the current version: |
Bundle ReportBundle size has no change ✅ |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@## build/linux/generate-glad-sources-at-compile-time #4852 +/- ##
=====================================================================================
- Coverage 17.52% 17.51% -0.02%
=====================================================================================
Files 106 106 Lines 21850 21856 +6 Branches 9751 9756 +5 =====================================================================================
- Hits 3829 3827 -2 + Misses 16110 14962 -1148 - Partials 1911 3067 +1156
Flags with carried forward coverage won't be shown. Click here to find out more.
|
e74ea2e
into
LizardByte:build/linux/generate-glad-sources-at-compile-timeUh oh!
There was an error while loading. Please reload this page.
* misc.cpp: phase 1 load (symbols only, defaults to EGL 1.0). * graphics.cpp: phase 2 load using correct display configuration with eglGetPlatformDisplayEXT (initializes proper EGL version dispatch). * Retain eglGetPlatformDisplay fallback if proprietary drivers need it. * Add missing/required extensions to GLAD makefile based on existing extensions queried & new eglGetPlatformDisplayEXT requirement. * Remove hardcoded definitions that are part of previously missing extensions.



eglGetPlatformDisplayEXT (initializes proper EGL version dispatch).
extensions queried & new eglGetPlatformDisplayEXT requirement.
extensions.
Description
Screenshot
Issues Fixed or Closed
Roadmap Issues
Type of Change
Checklist
AI Usage