]> xenbits.xensource.com Git - qemu-xen.git/commitdiff
egl: no need to lookup EGL functions manually
authorMarc-André Lureau <marcandre.lureau@redhat.com>
Tue, 18 Apr 2023 07:32:37 +0000 (11:32 +0400)
committerMarc-André Lureau <marcandre.lureau@redhat.com>
Tue, 27 Jun 2023 10:31:15 +0000 (12:31 +0200)
libepoxy handles loading the function pointer and dispatching the call,
so you don't have to worry about it.

Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-Id: <20230515132455.1025608-1-marcandre.lureau@redhat.com>

ui/egl-helpers.c

index 4203163acebf410d429fd2aab1dfca4cc7ff2af0..60385c1f48043433fd7a19b5c7e1dfbb8491d82a 100644 (file)
@@ -439,10 +439,8 @@ static EGLDisplay qemu_egl_get_display(EGLNativeDisplayType native,
 
     /* In practise any EGL 1.5 implementation would support the EXT extension */
     if (epoxy_has_egl_extension(NULL, "EGL_EXT_platform_base")) {
-        PFNEGLGETPLATFORMDISPLAYEXTPROC getPlatformDisplayEXT =
-            (void *) eglGetProcAddress("eglGetPlatformDisplayEXT");
-        if (getPlatformDisplayEXT && platform != 0) {
-            dpy = getPlatformDisplayEXT(platform, native, NULL);
+        if (platform != 0) {
+            dpy = eglGetPlatformDisplayEXT(platform, native, NULL);
         }
     }