GNOME Bugzilla – Bug 646341
[baseparse] Add a queued flow return so parsers can keep frames in a queue
Last modified: 2011-04-08 17:57:11 UTC
This is useful when a parser doesn't want to send buffers out until a certain point so it would return .._QUEUED from the parse function and when the next GST_FLOW_OK comes, baseparse will push the queued frames.
Created attachment 184784 [details] [review] patch to add a queued flow return and to queue buffers
Looks good, except that you should probably prepend the buffers and the either reverse the lsit before pushing or iterate the list from the tail. Also the queued buffers should be cleared when going back to READY or when receiving flush events
Looks like finalize performs a gst_mini_object_unref on the list items, which are frames rather than miniobjects.
> Looks like finalize performs a gst_mini_object_unref on the list items, which > are frames rather than miniobjects. Also, frames that were allocated on the stack...
Are you going to fix this patch and integrate it? Otherwise I'll do it later and use it in flacparse
I'll fix it and integrate it. Only just fixed my laptop, will try to push it all today or tomorrow.
commit 783dbb9a71045e640e93b2148adcf3a217e7546b Author: Zaheer Abbas Merali <zaheermerali@gmail.com> Date: Sat Apr 2 13:02:01 2011 +0100 baseparse: add GST_BASE_PARSE_FLOW_QUEUED to queue buffers until caps are known This is useful for parser like flacparse or h264parse which may need to process some buffers before they can construct the final caps, in which case they may want to delay pushing the initial buffers until the full and proper caps are known. https://bugzilla.gnome.org/show_bug.cgi?id=646341 commit 251dfa402cbfa8550eac45620dcd145403828511 Author: Tim-Philipp Müller <tim.muller@collabora.co.uk> Date: Sat Apr 2 14:04:42 2011 +0100 baseparse: use GQueue instead of GList for queued frames and make buffer metadata writable before setting caps on queued buffer. https://bugzilla.gnome.org/show_bug.cgi?id=646341
Comment on attachment 184784 [details] [review] patch to add a queued flow return and to queue buffers committed with changes.