From f4f0daa113ecd8bdec4e1f09cd00407c648650c3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pablo=20Correa=20G=C3=B3mez?= Date: Sat, 28 May 2022 01:01:19 +0200 Subject: [PATCH] macosglcontext: Do not rely on default from get_required_version get_required_version cannot warranty to return any default. Instead, fetch the user requisites clipped by the requirements in our backend. --- gdk/macos/gdkmacosglcontext.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/gdk/macos/gdkmacosglcontext.c b/gdk/macos/gdkmacosglcontext.c index ff7ae975c8..069d138b83 100644 --- a/gdk/macos/gdkmacosglcontext.c +++ b/gdk/macos/gdkmacosglcontext.c @@ -378,7 +378,10 @@ gdk_macos_gl_context_real_realize (GdkGLContext *context, existing = CGLGetCurrentContext (); - gdk_gl_context_get_required_version (context, &major, &minor); + gdk_gl_context_get_clipped_version (context, + GDK_GL_MIN_GL_VERSION_MAJOR, + GDK_GL_MIN_GL_VERSION_MINOR, + &major, &minor); display = gdk_gl_context_get_display (context); shared = gdk_display_get_gl_context (display);