GNOME Bugzilla – Bug 739808
problem with GstNavigation interface in vaapisink, registering for ButtonPressMask events
Last modified: 2014-11-27 09:32:40 UTC
Hi! Since commit 33212d9634, I have a crash occuring in banshee (Fedora 21, banshee 2.6.2 including a patch to make it work with gst-1.0) where a playbin (vaapidecode + vaapisink) pipeline is embedded in the application. It seems related to the fact that vaapisink registers for ButtonPressMask events, when the banshee widget already has registered for this same event. In this case, man XChangeWindowAttributes tells that a BadAccess error occurs, which is exactly what happens here.
Created attachment 290404 [details] [review] vaapisink: Protect the X11 API invokations with proper locking Could you please have a try with this patch?
If you doesn't want the vaapisink to handle the events then use gst_video_overlay_handle_events() API to disable it from the application. Does it make sense for your issue?
Patch from comment#1 doesn't fix it, but comment#2 is exactly what's needed. The code for that in libbanshee already should handle this : https://git.gnome.org/browse/banshee/tree/src/Backends/Banshee.GStreamer/libbanshee/banshee-player-video.c#n78 The code is similar to the gst-1.0 patch for banshee-2.6.2 backported in Fedora: http://pkgs.fedoraproject.org/cgit/banshee.git/tree/Initial-port-to-GStreamer-1.0.patch#n497 However I noticed that g_object_set(G_OBJECT (player->video_overlay), "handle-events", FALSE, NULL) is not executed. And if I add your suggested gst_video_overlay_handle_events (player->video_overlay, FALSE), then it works as expected.
The g_boject_set() could be working fine with software renderer like xvimagesink, because xvimagesink has a property like that. But vaapisink doesn't have the handle-events property, so you should use gst_video_overlay_handle_events() explicitly to disable the event handling.
Thanks for this precision. So I reassign the bug to banshee, as it seems to also concern the master branch of banshee, not just the gstreamer-1.0 patch to banshee-2.6.2 in Fedora.
Review of attachment 290404 [details] [review]: LGTM.
commit 267465d7d0824753c5e54a4802d8c51546b546f3 Author: Sreerenj Balachandran <sreerenj.balachandran@intel.com> Date: Thu Nov 27 11:14:50 2014 +0200 vaapisink: Protect the X11 API invokations with proper locking https://bugzilla.gnome.org/show_bug.cgi?id=739808