[Bug 680614] [0.11] audio base classes: _set_format called too soon

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Thu Jul 26 02:26:03 PDT 2012


https://bugzilla.gnome.org/show_bug.cgi?id=680614
  GStreamer | gst-plugins-good | git

Mark Nauwelaerts <mnauw> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |mnauw at users.sourceforge.net
            Summary|[flacenc] fix writing       |[0.11] audio base classes:
                   |metadata                    |_set_format called too soon

--- Comment #2 from Mark Nauwelaerts <mnauw at users.sourceforge.net> 2012-07-26 09:25:56 UTC ---
This is actually an effect of changed behaviour in 0.11, and could effect all
sorts of encoders in similar manner.

In both cases, _set_format is called when caps are set.  But in 0.10 this
typically happened when a buffer with data arrived (and so just before
something really had to be done), but in 0.11 this can happen way sooner (due
to caps event) where some tags or so still have to be received.

In short, changing this bug to reflect the underlying problem.
IMO, the solution to it is to change all codec base classes (where possible) to
only invoke _set_format when actual data is received, and at which time
something really has to be done.  Delaying it allows waiting for tags and also
has the benefit to handle "partial caps" in case it takes upstream a bit longer
to figure out all the parameters (codec-data or whatever) and may only send
complete caps after sending partial caps.

It is also still in line with the documentation saying (e.g.)
----
"GstAudioDecoder calls @set_format to inform subclass of the format
 of input audio data that it is about to receive."
----
and in current 0.11 the 'about' can actually be way sooner now, whereas the
suggestion restores it to the 'about' it used to be.

-- 
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.


More information about the gstreamer-bugs mailing list