[gst-devel] neutral buffer handling in sparse streams
Stefan Kost
ensonic at hora-obscura.de
Wed Oct 3 08:14:59 CEST 2007
hi,
Quoting Steve Fink <sphink at gmail.com>:
> On 10/1/07, Stefan Kost <ensonic at hora-obscura.de> wrote:
>> So what the way to go?
>>
>> 1) use GST_BUFFER_FLAG_GAP and define it as such
>> btw. its right now only used in
>> gst-plugins-base/gst/audiorate/gstaudiorate.c to
>> mark a silent filler-buffer
>>
>> 2) add GST_BUFFER_FLAG_NEUTRAL
>>
>> 3) segments
>>
>> 4) anything else?
>
> Perfect! I was about to experiment with adding a
> GST_BUFFER_FLAG_SILENCE for my stuff, so I'm happy to find out that
> such a flag already exists. I'll implement handling for it in
> gstadder.c.
>
> I don't know if this is kosher, but the other alternative I was
> considering was a zero-byte buffer with a nonzero duration. I don't
> know how that would get handled, though; it probably messes up bit
> rates.
>
> After reading the docs for GST_BUFFER_FLAG_GAP, though, it seems like
> it's already exactly what you want. How would your proposed definition
> be different from the one it already has?
>
Well, using GST_BUFFER_FLAG_GAP, works and I belive it won't break
anything. But while discussing this on IRC wtay argumented that the
flag is not clearly documented in a wat to justify the assumntions. It
says its a filler for a stream, but I would like to ssume its neutral.
The filler could also be comfort noise and any other pading signal.
Hence the suggestion to add another flag.
GST_BUFFER_FLAG_SILENCE was my first suggestion too, but as beeing
pointed out on IRC this would break the media agnostic design of core.
Silence is clearly related to audio only. So I suggested
GST_BUFFER_FLAG_NEUTRAL. I am open for alternative naming ideas.
But first lets agreee on the mechanism.
Stefan
More information about the gstreamer-devel
mailing list