[gstreamer-bugs] [Bug 392534] ffdemux enhancement: push based scheduling

GStreamer (bugzilla.gnome.org) bugzilla-daemon at bugzilla.gnome.org
Sun Jan 7 06:02:05 PST 2007


Do not reply to this via email (we are currently unable to handle email
responses and they get discarded).  You can add comments to this bug at
http://bugzilla.gnome.org/show_bug.cgi?id=392534

  GStreamer | gst-ffmpeg | Ver: 0.10.2





------- Comment #6 from Mark Nauwelaerts  2007-01-07 14:00 UTC -------
* OK, no problem for YUV4MPEG, the other 2 will be a bit closer together.
Do you mean I should attach the separate patches here, or to create separate
bug reports for these ?

* If I understand things correctly, tasks hold a lock while running in their
loop function, which in case of a pad_task is the STREAM_LOCK of the pad.  So,
if the existing sinkpad would be used, then both the _chain function and the
task would be trying to get the STREAM_LOCK, so things would block.  Both
_chain and the task must be able to run (fairly) independently (e.g. queue runs
the task on the src pad as well).  In this case, there is no specific src pad,
so a dummy pad was created.  I too had some concerns about possible problems,
but no problems have arisen so far during quite some testing, so I became less
suspicious ;-)
Admittedly, this is (as indicated) a slight hack, but a convenient one.
Considering the code and functionality of the gst_pad_xxx_task functions, they
offer a thin layer of additional functionality that a raw task does not have.
E.g. gst_pad_stop uses some lock tricks to make sure that the task will really
effectively stop and be joined.

So, basically, the hack intends to use the dummy pad as a collection of
"resources" (e.g. its STREAM_LOCK is a static recursive lock) and some
code/functionality, and everything else should be oblivious to this, as the pad
is not being added or registered anywhere, but serves only as a very local
private resource.  Of course, the (fairly small) relevant parts could also be
extracted out of this collection, thereby just making use of a GstTask.

In summary, unless otherwise suggested, I'll be adding 3 separate patches to
this bug, and replacing dummy pad with using a GstTask (and corresponding
code).


-- 
Configure bugmail: http://bugzilla.gnome.org/userprefs.cgi?tab=email




More information about the Gstreamer-bugs mailing list