mirror of
https://github.com/glfw/glfw.git
synced 2026-09-19 15:25:50 +00:00
Null: Add limited EGL context creation on Mesa
This provides very limited support for context creation via EGL on the Null platform. It supports Unix-like systems with a version of Mesa that provides EGL_MESA_platform_surfaceless. Even then, the actual framebuffer provided is not resized along with the 'window'. That will hopefully change once context and framebuffer creation are separated, but this commit should at least allow more applications than before to run on the Null platform.
This commit is contained in:
+5
-2
@@ -553,12 +553,15 @@ const char* _glfwGetClipboardStringNull(void)
|
||||
|
||||
EGLenum _glfwGetEGLPlatformNull(EGLint** attribs)
|
||||
{
|
||||
return 0;
|
||||
if (_glfw.egl.EXT_platform_base && _glfw.egl.MESA_platform_surfaceless)
|
||||
return EGL_PLATFORM_SURFACELESS_MESA;
|
||||
else
|
||||
return 0;
|
||||
}
|
||||
|
||||
EGLNativeDisplayType _glfwGetEGLNativeDisplayNull(void)
|
||||
{
|
||||
return 0;
|
||||
return EGL_DEFAULT_DISPLAY;
|
||||
}
|
||||
|
||||
EGLNativeWindowType _glfwGetEGLNativeWindowNull(_GLFWwindow* window)
|
||||
|
||||
Reference in New Issue
Block a user