为什么 QtCompositor 初始化 EGL 显示失败?

Why QtCompositor is failed to initialize EGL display?

正在尝试在 Kaby Lake 系统和 Sky Lake 系统上 运行 QWaylandCompositor 示例代码 "qwindow-compositor"。但它显示为

QtCompositor: Failed to initialize EGL display. Could not get EglDisplay for window.

我需要做什么来解决这个问题?

自述文件

Testing a Qt-based compositor on X11:

Most QWidget-based applications will use shared memory buffers, which work on all hardware. OpenGL and Qt Quick applications need a way to send graphics memory buffers from client to server. There are many options, and not all options work on all hardware.

The X Composite buffer integration should work on all modern X servers. It can be used with either EGL or GLX as the OpenGL backend. This must match the backend used by the xcb platform plugin. (Normally GLX is the default for Qt applications running on X11.) To use the X Composite buffer sharing with EGL, start the compositor as follows:

QT_XCB_GL_INTEGRATION=xcb_egl QT_WAYLAND_CLIENT_BUFFER_INTEGRATION=xcomposite-egl ./pure-qml

只需将 pure-qml 换成 qwindow-compositor

就我而言,我的系统中缺少以下库

libgles2-mesa libgles2-mesa-dev