aboutsummaryrefslogtreecommitdiff
path: root/ui/gtk-egl.c
diff options
context:
space:
mode:
authorMarc-André Lureau <marcandre.lureau@redhat.com>2021-10-09 23:48:46 +0400
committerMarc-André Lureau <marcandre.lureau@redhat.com>2021-12-21 10:50:21 +0400
commit5e79d516e8ac818d2a90aae9f787775055434ee9 (patch)
tree572cadfe13cb13f683b0be625929427dbca469e6 /ui/gtk-egl.c
parent7cc712e9862ffdbe4161dbdf3bbf41bcbe547472 (diff)
ui: split the GL context in a different object
This will allow to have one GL context but a variable number of listeners. Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com> Acked-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'ui/gtk-egl.c')
-rw-r--r--ui/gtk-egl.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/ui/gtk-egl.c b/ui/gtk-egl.c
index e891b61048..e3bd4bc274 100644
--- a/ui/gtk-egl.c
+++ b/ui/gtk-egl.c
@@ -197,14 +197,14 @@ void gd_egl_switch(DisplayChangeListener *dcl,
}
}
-QEMUGLContext gd_egl_create_context(DisplayChangeListener *dcl,
+QEMUGLContext gd_egl_create_context(DisplayGLCtx *dgc,
QEMUGLParams *params)
{
- VirtualConsole *vc = container_of(dcl, VirtualConsole, gfx.dcl);
+ VirtualConsole *vc = container_of(dgc, VirtualConsole, gfx.dgc);
eglMakeCurrent(qemu_egl_display, vc->gfx.esurface,
vc->gfx.esurface, vc->gfx.ectx);
- return qemu_egl_create_context(dcl, params);
+ return qemu_egl_create_context(dgc, params);
}
void gd_egl_scanout_disable(DisplayChangeListener *dcl)
@@ -360,10 +360,10 @@ void gtk_egl_init(DisplayGLMode mode)
display_opengl = 1;
}
-int gd_egl_make_current(DisplayChangeListener *dcl,
+int gd_egl_make_current(DisplayGLCtx *dgc,
QEMUGLContext ctx)
{
- VirtualConsole *vc = container_of(dcl, VirtualConsole, gfx.dcl);
+ VirtualConsole *vc = container_of(dgc, VirtualConsole, gfx.dgc);
return eglMakeCurrent(qemu_egl_display, vc->gfx.esurface,
vc->gfx.esurface, ctx);