mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-04-26 06:54:49 +00:00
Restore GLX context only if there is one.
This commit is contained in:
parent
c9f62b7405
commit
72fb4f6def
1 changed files with 2 additions and 1 deletions
|
@ -276,7 +276,8 @@ gst_vaapi_window_glx_resize(GstVaapiWindow *window, guint width, guint height)
|
||||||
GST_VAAPI_OBJECT_LOCK_DISPLAY(window);
|
GST_VAAPI_OBJECT_LOCK_DISPLAY(window);
|
||||||
if (gl_make_current(dpy, GST_VAAPI_OBJECT_ID(window), priv->context, &cs)) {
|
if (gl_make_current(dpy, GST_VAAPI_OBJECT_ID(window), priv->context, &cs)) {
|
||||||
gl_resize(width, height);
|
gl_resize(width, height);
|
||||||
gl_make_current(dpy, cs.window, cs.context, NULL);
|
if (cs.context)
|
||||||
|
gl_make_current(dpy, cs.window, cs.context, NULL);
|
||||||
}
|
}
|
||||||
GST_VAAPI_OBJECT_UNLOCK_DISPLAY(window);
|
GST_VAAPI_OBJECT_UNLOCK_DISPLAY(window);
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|
Loading…
Reference in a new issue