summaryrefslogtreecommitdiffstats
path: root/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
diff options
context:
space:
mode:
authorSamuli Piippo <samuli.piippo@qt.io>2020-02-26 16:14:30 +0200
committerSamuli Piippo <samuli.piippo@qt.io>2020-03-05 08:19:05 +0200
commit7458370a6facf4261df90eea7230382756608a2e (patch)
tree0176e9ab23c667495faea50cc8db56b2fae95a61 /src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
parent9bea5d5cb8f48bd5602e1a45cf8817f7e5f320c8 (diff)
Test the EGL wayland platform extensions before using them
The Khronos headers may be recent enough to have the ifdefs but implementation might still be missing on some platforms. Don't use the extensions unless the configure test passes. Change-Id: I23129115729567fa92bc23da099d27df598fc206 Reviewed-by: James McDonnell <jmcdonnell@blackberry.com>
Diffstat (limited to 'src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp')
-rw-r--r--src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp b/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
index 8ea8e1092..02affe31b 100644
--- a/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
+++ b/src/hardwareintegration/client/wayland-egl/qwaylandglcontext.cpp
@@ -346,7 +346,7 @@ void QWaylandGLContext::updateGLFormat()
wl_surface *wlSurface = m_display->createSurface(nullptr);
wl_egl_window *eglWindow = wl_egl_window_create(wlSurface, 1, 1);
-#if defined(EGL_VERSION_1_5)
+#if QT_CONFIG(egl_extension_platform_wayland)
EGLSurface eglSurface = eglCreatePlatformWindowSurface(m_eglDisplay, m_config, eglWindow, nullptr);
#else
EGLSurface eglSurface = eglCreateWindowSurface(m_eglDisplay, m_config, eglWindow, nullptr);