mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-04 00:03:54 -06:00
ui: add egl-headless support on win32
Make GBM optional for EGL code, and enable the build for win32. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Message-Id: <20230606115658.677673-13-marcandre.lureau@redhat.com>
This commit is contained in:
parent
48dddba176
commit
39324b4966
5 changed files with 55 additions and 21 deletions
|
@ -79,6 +79,8 @@ static void egl_scanout_texture(DisplayChangeListener *dcl,
|
|||
}
|
||||
}
|
||||
|
||||
#ifdef CONFIG_GBM
|
||||
|
||||
static void egl_scanout_dmabuf(DisplayChangeListener *dcl,
|
||||
QemuDmaBuf *dmabuf)
|
||||
{
|
||||
|
@ -110,6 +112,14 @@ static void egl_cursor_dmabuf(DisplayChangeListener *dcl,
|
|||
}
|
||||
}
|
||||
|
||||
static void egl_release_dmabuf(DisplayChangeListener *dcl,
|
||||
QemuDmaBuf *dmabuf)
|
||||
{
|
||||
egl_dmabuf_release_texture(dmabuf);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
static void egl_cursor_position(DisplayChangeListener *dcl,
|
||||
uint32_t pos_x, uint32_t pos_y)
|
||||
{
|
||||
|
@ -119,12 +129,6 @@ static void egl_cursor_position(DisplayChangeListener *dcl,
|
|||
edpy->pos_y = pos_y;
|
||||
}
|
||||
|
||||
static void egl_release_dmabuf(DisplayChangeListener *dcl,
|
||||
QemuDmaBuf *dmabuf)
|
||||
{
|
||||
egl_dmabuf_release_texture(dmabuf);
|
||||
}
|
||||
|
||||
static void egl_scanout_flush(DisplayChangeListener *dcl,
|
||||
uint32_t x, uint32_t y,
|
||||
uint32_t w, uint32_t h)
|
||||
|
@ -160,10 +164,12 @@ static const DisplayChangeListenerOps egl_ops = {
|
|||
|
||||
.dpy_gl_scanout_disable = egl_scanout_disable,
|
||||
.dpy_gl_scanout_texture = egl_scanout_texture,
|
||||
#ifdef CONFIG_GBM
|
||||
.dpy_gl_scanout_dmabuf = egl_scanout_dmabuf,
|
||||
.dpy_gl_cursor_dmabuf = egl_cursor_dmabuf,
|
||||
.dpy_gl_cursor_position = egl_cursor_position,
|
||||
.dpy_gl_release_dmabuf = egl_release_dmabuf,
|
||||
#endif
|
||||
.dpy_gl_cursor_position = egl_cursor_position,
|
||||
.dpy_gl_update = egl_scanout_flush,
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue