diff options
author | Olivier Fourdan <ofourdan@redhat.com> | 2021-05-17 18:20:57 +0200 |
---|---|---|
committer | Olivier Fourdan <ofourdan@redhat.com> | 2021-06-21 11:16:58 +0200 |
commit | 2e1bb50644ce2553451da74506f8f26cb7222a8f (patch) | |
tree | 9a06afda622a9ce3ac120db4b243433839989346 | |
parent | 8744ab1b417018888d2d1192a09aae16d06fc20c (diff) | |
download | xserver-2e1bb50644ce2553451da74506f8f26cb7222a8f.tar.gz |
xwayland/eglstream: Use "nvidia" for GLVND
If the EGLStream backend is able to use hardware acceleration with the
NVIDIA closed source driver, we should use the "nvidia" GLX
implementation instead of the one from Mesa to take advantage of the
NVIDIA hardware accelerated rendering.
Signed-off-by: Olivier Fourdan <ofourdan@redhat.com>
Reviewed-by: Michel Dänzer <mdaenzer@redhat.com>
(cherry picked from commit fae58e9b03696a3890f9c876306c68ffa6f9ff30)
-rw-r--r-- | hw/xwayland/xwayland-glamor-eglstream.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/hw/xwayland/xwayland-glamor-eglstream.c b/hw/xwayland/xwayland-glamor-eglstream.c index c583a1390..5e89849ff 100644 --- a/hw/xwayland/xwayland-glamor-eglstream.c +++ b/hw/xwayland/xwayland-glamor-eglstream.c @@ -1195,9 +1195,11 @@ xwl_glamor_eglstream_init_egl(struct xwl_screen *xwl_screen) xwl_eglstream_init_shaders(xwl_screen); - if (epoxy_has_gl_extension("GL_OES_EGL_image") && - !dri3_screen_init(xwl_screen->screen, &xwl_dri3_info)) { - ErrorF("DRI3 initialization failed. Performance will be affected.\n"); + if (epoxy_has_gl_extension("GL_OES_EGL_image")) { + if (dri3_screen_init(xwl_screen->screen, &xwl_dri3_info)) + xwl_screen->glvnd_vendor = "nvidia"; + else + ErrorF("DRI3 initialization failed. Performance will be affected.\n"); } return TRUE; |