mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
Init the X11 threads as first thing on X11 in the GTK sample
This commit is contained in:
parent
865476e5fc
commit
a9ebf7e38e
2 changed files with 9 additions and 0 deletions
|
@ -19,6 +19,9 @@ public class MainWindow : Gtk.Window {
|
|||
bool _pipelineOK = false;
|
||||
|
||||
public static void Main (string[] args) {
|
||||
if (System.Environment.OSVersion.Platform == PlatformID.Unix)
|
||||
XInitThreads ();
|
||||
|
||||
Gtk.Application.Init ();
|
||||
Gst.Application.Init ();
|
||||
MainWindow window = new MainWindow ();
|
||||
|
@ -262,4 +265,7 @@ public class MainWindow : Gtk.Window {
|
|||
[DllImport ("libgdk-win32-2.0-0.dll") ]
|
||||
static extern bool gdk_window_ensure_native (IntPtr handle);
|
||||
#endif
|
||||
|
||||
[DllImport ("libX11.so.6")]
|
||||
static extern int XInitThreads ();
|
||||
}
|
||||
|
|
3
samples/gtk-video-player.exe.config
Normal file
3
samples/gtk-video-player.exe.config
Normal file
|
@ -0,0 +1,3 @@
|
|||
<configuration>
|
||||
<dllmap dll="libgdk-win32-2.0-0.dll" target="libgdk-x11-2.0.so.0"/>
|
||||
</configuration>
|
Loading…
Reference in a new issue