From 4f6c226bd24ae3ef66bd8f4c17b001444c9b0bf1 Mon Sep 17 00:00:00 2001 From: Matthew Waters Date: Fri, 1 Jul 2016 00:07:23 +1000 Subject: gl/x11: use xcb instead of libX11 - xcb is supposedly thread-safe! videotestsrc ! glimagesink now doesn't spuriously result in a 'call XInitThreads()' error however if anybody else is using X11, then XInitThreads() still needs to be called and multiple glimagesink's still need XInitThreads(). Everything still takes libX11 handles as they are compatible with the xcb variants. Unfortunately we cannot move fully over to xcb due to GLX being entirely based on Xlib. It's also impossible to transform a xcb_connection to a Display which means we require X11 handles. --- gst-libs/gst/gl/x11/xcb_event_source.h | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 gst-libs/gst/gl/x11/xcb_event_source.h (limited to 'gst-libs/gst/gl/x11/xcb_event_source.h') diff --git a/gst-libs/gst/gl/x11/xcb_event_source.h b/gst-libs/gst/gl/x11/xcb_event_source.h new file mode 100644 index 000000000..ba476352a --- /dev/null +++ b/gst-libs/gst/gl/x11/xcb_event_source.h @@ -0,0 +1,29 @@ +/* + * GStreamer + * Copyright (C) 2012 Matthew Waters + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, + * Boston, MA 02110-1301, USA. + */ + +#ifndef __XCB_EVENT_SOURCE_H__ +#define __XCB_EVENT_SOURCE_H__ + +#include +#include "gstgldisplay_x11.h" + +GSource * xcb_event_source_new (GstGLDisplayX11 *display_x11); + +#endif /* __XCB_EVENT_SOURCE_H__ */ -- cgit v1.2.3