[Bug 737599] Some decoders need AVI's header suggested buffer size

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Tue Sep 30 00:50:23 PDT 2014


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

--- Comment #5 from alfonso.sanchez-beato at canonical.com 2014-09-30 07:50:14 UTC ---
Ok. Let's discuss about the general solution. Certainly, the ideal situation
would be to have the right input buffer size from the start, and we must try to
do that for any stream. However, calculating the input buffer size can be
tricky, especially in cases like live streams. Therefore, in some cases we will
need to re-allocate input buffers, and it is something that must be supported
by the media stack. But this is costly in terms of time, especially for
hardware decoders, as we could need to gather contiguous physical memory, flash
caches, etc., possible causing video freezes. So we should avoid that if
possible.

In case the stream/container already provides a sensible suggestion for the
input buffer size, we can take it as an *optional* parameter for our initial
calculations of the buffer size, so we avoid the situation just described. So
this change fits in that situation (it provides information that can be used as
part of the parameters for calculating the input buffer size) and it is then
part of the general solution. In case other containers provide this kind of
information we could also use it, once we agree on the name and format of the
parameter: it is not vendor specific stuff. Note that this does not conflict
with the need to support buffer re-allocation: it is just a way to diminish the
chance of having to re-allocate.

I do not see this as really different from the "width" and "height" that are
filled in GstCaps, as we could also calculate them from the stream instead of
using those in the container. But it is convenient to get them from the
container.

-- 
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