spice: add cursor_dmabuf support

Add support for cursor dmabufs.  qemu has to render the cursor for
that, so in case a cursor is present qemu allocates a new dmabuf, blits
the scanout, blends in the pointer and passes on the new dmabuf to
spice-server.  Without cursor qemu continues to simply pass on the
scanout dmabuf as-is.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Marc-André Lureau <marcandre.lureau@redhat.com>
Message-id: 20180308090618.30147-4-kraxel@redhat.com
This commit is contained in:
Gerd Hoffmann 2018-03-08 10:06:17 +01:00
parent cd2452b279
commit b153f9019b
3 changed files with 121 additions and 5 deletions

View file

@ -122,6 +122,15 @@ struct SimpleSpiceDisplay {
int gl_updates;
bool have_scanout;
bool have_surface;
QemuDmaBuf *guest_dmabuf;
bool guest_dmabuf_refresh;
bool render_cursor;
egl_fb guest_fb;
egl_fb blit_fb;
egl_fb cursor_fb;
bool have_hot;
#endif
};