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 584686 - [playbin2] Need {audio,video,text}-tags-changed signals
[playbin2] Need {audio,video,text}-tags-changed signals
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-base
git master
Other Linux
: Normal enhancement
: 0.10.24
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks: 584689
 
 
Reported: 2009-06-03 07:44 UTC by Sebastian Dröge (slomo)
Modified: 2009-06-04 13:47 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Sebastian Dröge (slomo) 2009-06-03 07:44:59 UTC
Hi,
it'd be nice if playbin2 had {audio,video,text}-tags-changed signals that are emitted whenever the tags are changed so one can call get-{a,v,t}-tags to get the latest tags.

Currently this can only be done by polling get-{a,v,t}-tags or by installing an event probe on the a/v/t pads.
Comment 1 Wim Taymans 2009-06-03 09:47:45 UTC
could be done by proxying the property notify of the inputselector.
Comment 2 Sebastian Dröge (slomo) 2009-06-04 07:00:16 UTC
Ok, done :)

commit 28b366db00bbc591325549417b668f18a5d4d949
Author: Sebastian Dröge <sebastian.droege@collabora.co.uk>
Date:   Thu Jun 4 08:57:24 2009 +0200

    playbin2: API: Add {audio,video,text}-tags-changed signals
    
    Fixes bug #584686.

commit a0ad632320eb4b29b873e8c9058e01dde4a21535
Author: Sebastian Dröge <sebastian.droege@collabora.co.uk>
Date:   Thu Jun 4 08:56:29 2009 +0200

    inputselector: Notify when the tags property of the selector sinkpads change
    
    First part of bug #584686.
Comment 3 Tim-Philipp Müller 2009-06-04 08:35:47 UTC
Why do we keep adding signal notify stuff emitted from streaming threads everywhere? This sucked, a lot, in 0.8, and nothing much has changed since then:

 - it's painful for apps, since they have to marshal
   things into the main thread (not to mention that
   those poor souls who just wanted to write a simple
   player using playbin2 have to learn about threading
   and marshalling things into the other threads).

 - it's racy and may lead to crashes due to still
   unfixed GObject bugs.

 - it's hard to extend (add new arguments etc.)

In fact, the only upside I can see is that it's introspectable via gst-inspect.

Can we please come up with a better system for these things?
Comment 4 Tim-Philipp Müller 2009-06-04 08:40:00 UTC
(Ok, so this isn't a notify signal, but other than the notify raciness my points still apply, I think.)
Comment 5 Sebastian Dröge (slomo) 2009-06-04 13:38:13 UTC
In 0.11 I'd propose that the sinks are the only elements that post tags as messages on the bus... then this wouldn't be a problem anymore.


Other than a signal for the tags-changed stuff a element message could be used as well, right. I've used a signal because similar things are already done as signal in playbin2 for consistency and because it's a proxy signal for the notify::caps signal of the input-selector sinkpads.
Comment 6 Wim Taymans 2009-06-04 13:47:39 UTC
Comment #5: I was actually going to implement this in 0.10 already but then I ran into some problems in basesink and stopped the attempt.