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 670850 - collectpads2 port of adder has a regression for buzztard
collectpads2 port of adder has a regression for buzztard
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-base
0.10.x
Other Linux
: Normal blocker
: 0.10.37
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2012-02-26 21:43 UTC by Stefan Sauer (gstreamer, gtkdoc dev)
Modified: 2012-02-28 20:05 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
the pipeline dump (114.11 KB, image/svg+xml)
2012-02-26 21:46 UTC, Stefan Sauer (gstreamer, gtkdoc dev)
  Details
buzztard song to reproduce the bug (879 bytes, audio/x-bzt)
2012-02-26 21:46 UTC, Stefan Sauer (gstreamer, gtkdoc dev)
  Details
WIP patch, not yet fixing the problem (6.07 KB, patch)
2012-02-27 11:10 UTC, Stefan Sauer (gstreamer, gtkdoc dev)
committed Details | Review

Description Stefan Sauer (gstreamer, gtkdoc dev) 2012-02-26 21:43:40 UTC
Having a simple song like:

src ! fx ! sink src ! sink

does not play anymore. After a git revert -n 85c10b0 1da30ad bcaf589 a3c5abf it works again. The above is more complex that it looks. In buzztard src, fx and sink are bins with additional volume and level elements. src ends on a tee, fx has an adder at the begin and tee at the end and sink begins with an adder. Each link (!) is a bin as well, consisting of queue , volume, panorama and audioconvert elements. I am attaching a pipeline dump.

It can be reproduced by
buzztard-cmd -c play -i collectpads2bug.bzt
buzztard-edit -c load -i collectpads2bug.bzt
(and then pressing play). The released 0.6'er version should do.
Comment 1 Stefan Sauer (gstreamer, gtkdoc dev) 2012-02-26 21:46:05 UTC
Created attachment 208454 [details]
the pipeline dump

One can see that the src pad of the most downstream adder is not negotiated. How this is caused by the collectpads transition is not clear to me as neither collectpads nor collectpads2 do anything with caps.
Comment 2 Stefan Sauer (gstreamer, gtkdoc dev) 2012-02-26 21:46:51 UTC
Created attachment 208455 [details]
buzztard song to reproduce the bug
Comment 3 Stefan Sauer (gstreamer, gtkdoc dev) 2012-02-26 22:29:29 UTC
The issue is that some pads are left flushing.
Comment 4 Stefan Sauer (gstreamer, gtkdoc dev) 2012-02-27 09:44:49 UTC
git bisect start gst/adder
git bisect good 14644457b06f48b26f32f88ef91e1286a48ebe24
git bisect bad origin/master
Bisecting: 2 revisions left to test after this (roughly 1 step)
[bcaf5890aa6eb1c4a18b8dd71eacb22aadba0ead] adder: send a flush event before trying to get the stream lock

git bisect good
Bisecting: 0 revisions left to test after this (roughly 1 step)
[85c10b0b24a58c1b5ec9aa05ea4ffa98ba99ed76] adder: do not send too many flush-stop events

git bisect bad
Bisecting: 0 revisions left to test after this (roughly 0 steps)
[1da30adc1aeafd36b15b8d083fe2178524619479] adder: use the stream lock where appropriate

git bisect good
85c10b0b24a58c1b5ec9aa05ea4ffa98ba99ed76 is the first bad commit
commit 85c10b0b24a58c1b5ec9aa05ea4ffa98ba99ed76
Author: Vincent Penquerc'h <vincent.penquerch@collabora.co.uk>
Date:   Fri Dec 16 17:32:41 2011 +0000

    adder: do not send too many flush-stop events
    
    GstCollectPads2 now allows us to override the event function,
    so we can withhold flush stop events if none are to be sent.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=666379

:040000 040000 da80620b5dfd1bdde682e232755382e98f87913a c8ec51e6b51c268e764184cdff45d304fc629eea M	gst

and indeed just git revert -n 85c10b0 make it work again.
Comment 5 Stefan Sauer (gstreamer, gtkdoc dev) 2012-02-27 11:10:15 UTC
Created attachment 208480 [details] [review]
WIP patch, not yet fixing the problem
Comment 6 Stefan Sauer (gstreamer, gtkdoc dev) 2012-02-28 19:55:49 UTC
commit ce1b1d82e34b5ee9eaf6ab979799e52c6d558929
Author: Stefan Sauer <ensonic@users.sf.net>
Date:   Mon Feb 27 11:57:55 2012 +0100

    adder: sink event handling fix
    
    Turn _sink_event() into the collectpads event function and merge the logic from
    the recently added gst_adder_event. Drop flush_start events as we allready
    handle them on the src-pad side. Fixes #670850.