summaryrefslogtreecommitdiffstats
path: root/ui/gtk-egl.c
diff options
context:
space:
mode:
authorAkihiko Odaki2021-02-23 07:03:07 +0100
committerGerd Hoffmann2021-03-04 09:35:30 +0100
commitbc6a3565c89243f0aaa24bac6dc37fb52b16d5c5 (patch)
treec67c6b57bd5832fbf17c70bc2fae1d9c91d54b91 /ui/gtk-egl.c
parentui/cocoa: Fix stride resolution of pixman image (diff)
downloadqemu-bc6a3565c89243f0aaa24bac6dc37fb52b16d5c5.tar.gz
qemu-bc6a3565c89243f0aaa24bac6dc37fb52b16d5c5.tar.xz
qemu-bc6a3565c89243f0aaa24bac6dc37fb52b16d5c5.zip
configure: Improve OpenGL dependency detections
This has the following visible changes: - GBM is required only for OpenGL dma-buf. - X11 is explicitly required by gtk-egl. - EGL is now mandatory for the OpenGL displays. The last one needs some detailed description. Before this change, EGL was tested only for OpenGL dma-buf with the check of EGL_MESA_image_dma_buf_export. However, all of the OpenGL displays depend on EGL and EGL_MESA_image_dma_buf_export is always defined by epoxy's EGL interface. Therefore, it makes more sense to always check the presence of EGL and say the OpenGL displays are available along with OpenGL dma-buf if it is present. Signed-off-by: Akihiko Odaki <akihiko.odaki@gmail.com> Message-Id: <20210223060307.87736-1-akihiko.odaki@gmail.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'ui/gtk-egl.c')
-rw-r--r--ui/gtk-egl.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/ui/gtk-egl.c b/ui/gtk-egl.c
index 588e7b1bb1..2a2e6d3a17 100644
--- a/ui/gtk-egl.c
+++ b/ui/gtk-egl.c
@@ -208,7 +208,7 @@ void gd_egl_scanout_texture(DisplayChangeListener *dcl,
void gd_egl_scanout_dmabuf(DisplayChangeListener *dcl,
QemuDmaBuf *dmabuf)
{
-#ifdef CONFIG_OPENGL_DMABUF
+#ifdef CONFIG_GBM
egl_dmabuf_import_texture(dmabuf);
if (!dmabuf->texture) {
return;
@@ -224,7 +224,7 @@ void gd_egl_cursor_dmabuf(DisplayChangeListener *dcl,
QemuDmaBuf *dmabuf, bool have_hot,
uint32_t hot_x, uint32_t hot_y)
{
-#ifdef CONFIG_OPENGL_DMABUF
+#ifdef CONFIG_GBM
VirtualConsole *vc = container_of(dcl, VirtualConsole, gfx.dcl);
if (dmabuf) {
@@ -252,7 +252,7 @@ void gd_egl_cursor_position(DisplayChangeListener *dcl,
void gd_egl_release_dmabuf(DisplayChangeListener *dcl,
QemuDmaBuf *dmabuf)
{
-#ifdef CONFIG_OPENGL_DMABUF
+#ifdef CONFIG_GBM
egl_dmabuf_release_texture(dmabuf);
#endif
}