After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 755662 - backend: reenable dvd events
backend: reenable dvd events
Status: RESOLVED FIXED
Product: totem
Classification: Core
Component: general
unspecified
Other All
: Normal normal
: ---
Assigned To: General Totem maintainer(s)
General Totem maintainer(s)
: 755531 (view as bug list)
Depends on: 755680
Blocks:
 
 
Reported: 2015-09-26 11:09 UTC by Lionel Landwerlin
Modified: 2015-10-02 16:55 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
backend: reenable dvd events (6.24 KB, patch)
2015-09-26 11:09 UTC, Lionel Landwerlin
none Details | Review
backend: reenable dvd events (6.18 KB, patch)
2015-09-27 15:33 UTC, Lionel Landwerlin
none Details | Review
backend: reenable dvd events (5.20 KB, patch)
2015-09-30 17:56 UTC, Lionel Landwerlin
committed Details | Review

Description Lionel Landwerlin 2015-09-26 11:09:45 UTC
The move to ClutterGst 3 resulted in navigation events to be dropped on the
floor. Let's reenable this in Totem.

You will need https://git.gnome.org/browse/clutter-gst/commit/?id=483d5868c3afb320023fcd314ee4300b9fdbe36d
to make this work (release coming as soon as we verify this works).

I managed to get the gstreamer dvd elements to be notified of the events on
a custom dvd directory, but for some reason there is nothing going on. Not
having a actual DVD drive and DVD disc, it would be good to verify this with
actual hardware.

Thanks!
Comment 1 Lionel Landwerlin 2015-09-26 11:09:50 UTC
Created attachment 312191 [details] [review]
backend: reenable dvd events

With ClutterGst 3 the video is provided through a ClutterContent that
doesn't know about the scenegraph and the events. Let's listen to events in
Totem to transmit them to the video sink throught the navigation interface.
Comment 2 Bastien Nocera 2015-09-26 12:34:50 UTC
*** Bug 755531 has been marked as a duplicate of this bug. ***
Comment 3 Bastien Nocera 2015-09-26 12:53:46 UTC
Review of attachment 312191 [details] [review]:

This doesn't work for me, events are getting sent to navigation_event(), and it's sending events down to GStreamer, but it's not doing anything here...

I'm pretty sure that it might conflict with bacon_video_widget_motion_notify() as well.

::: src/backend/bacon-video-widget.c
@@ +5931,3 @@
+
+  if (event->type == CLUTTER_MOTION) {
+    ClutterMotionEvent *mevent = (ClutterMotionEvent *) event;

mevent isn't used.
Comment 4 Lionel Landwerlin 2015-09-27 15:33:10 UTC
Created attachment 312241 [details] [review]
backend: reenable dvd events

With ClutterGst 3 the video is provided through a ClutterContent that
doesn't know about the scenegraph and the events. Let's listen to events in
Totem to transmit them to the video sink throught the navigation interface.
Comment 5 Lionel Landwerlin 2015-09-27 15:34:26 UTC
It works now, but you will need :

http://cgit.freedesktop.org/gstreamer/gst-plugins-bad/commit/?id=0e18ae586b10a26409ec2fb14fc65903a5d6fe2d

and also the top of the clutter-gst-3.0 branch (just pushed).
Comment 6 Jan Schmidt 2015-09-27 15:41:16 UTC
You only need that -bad patch for your specific test iso image - most DVDs would work fine.
Comment 7 Bastien Nocera 2015-09-27 15:51:27 UTC
Review of attachment 312241 [details] [review]:

If you look at Jan's 9490db5c708dbc5bb9bf482b4b596629e6cf170c commit, you'll see that we try to pass the raw events back to the application, which will then push it back down GStreamer through bacon_video_widget_dvd_event().

I'll try to fix that up to my liking, but thanks very much for the clutter-gst3 fix-up.

::: src/backend/bacon-video-widget.c
@@ +5937,3 @@
+    ClutterButtonEvent *bevent = (ClutterButtonEvent *) event;
+    const char *type;
+    type = (event->type == CLUTTER_BUTTON_PRESS) ?

That's fine on one line.

@@ +5957,3 @@
+        command = GST_NAVIGATION_COMMAND_RIGHT;
+        break;
+      case CLUTTER_KEY_Return:

Missing keypad return here.

I find it a bit weird that we need to handle keys here, when we have something similar in totem-object.c (look for GDK_KEY_Return).
Comment 8 Lionel Landwerlin 2015-09-30 17:56:43 UTC
Created attachment 312443 [details] [review]
backend: reenable dvd events

With ClutterGst 3 the video is provided through a ClutterContent that
doesn't know about the scenegraph and the events. Let's listen to events in
Totem to transmit them to the video sink throught the navigation interface.
Comment 9 Lionel Landwerlin 2015-09-30 17:56:54 UTC
Review of attachment 312241 [details] [review]:

::: src/backend/bacon-video-widget.c
@@ +5937,3 @@
+    ClutterButtonEvent *bevent = (ClutterButtonEvent *) event;
+    const char *type;
+  clutter_event_get_coords (event, &x, &y);

Done.

@@ +5957,3 @@
+        command = GST_NAVIGATION_COMMAND_RIGHT;
+        break;
+    gst_navigation_send_mouse_event (GST_NAVIGATION (bvw->priv->video_sink),

Yeah, copied from ClutterGst 2.0, removing