summary refs log tree commit diff stats
path: root/ui/sdl2.c
diff options
context:
space:
mode:
authorGerd Hoffmann <kraxel@redhat.com>2014-11-19 14:56:46 +0100
committerGerd Hoffmann <kraxel@redhat.com>2016-01-08 12:20:15 +0100
commitcb47dc9ab9f55083017291b2b8fbae639c576ec2 (patch)
tree471fa94f134c554cd757926948e5d47297806adb /ui/sdl2.c
parent4083733db5e4120939acee57019ff52db1f45b9d (diff)
downloadfocaccia-qemu-cb47dc9ab9f55083017291b2b8fbae639c576ec2.tar.gz
focaccia-qemu-cb47dc9ab9f55083017291b2b8fbae639c576ec2.zip
sdl2/opengl: add opengl context and scanout support
This allows virtio-gpu to render in 3d mode.

Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Diffstat (limited to 'ui/sdl2.c')
-rw-r--r--ui/sdl2.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/ui/sdl2.c b/ui/sdl2.c
index cf38df2684..46270f4172 100644
--- a/ui/sdl2.c
+++ b/ui/sdl2.c
@@ -700,6 +700,13 @@ static const DisplayChangeListenerOps dcl_gl_ops = {
     .dpy_refresh             = sdl2_gl_refresh,
     .dpy_mouse_set           = sdl_mouse_warp,
     .dpy_cursor_define       = sdl_mouse_define,
+
+    .dpy_gl_ctx_create       = sdl2_gl_create_context,
+    .dpy_gl_ctx_destroy      = sdl2_gl_destroy_context,
+    .dpy_gl_ctx_make_current = sdl2_gl_make_context_current,
+    .dpy_gl_ctx_get_current  = sdl2_gl_get_current_context,
+    .dpy_gl_scanout          = sdl2_gl_scanout,
+    .dpy_gl_update           = sdl2_gl_scanout_flush,
 };
 #endif