[gst-devel] thoughts on extradata

Ronald S. Bultje R.S.Bultje at students.uu.nl
Sun Mar 14 20:07:09 CET 2004


Hi,

matroska and quicktime know the concept of pre-stream data. Quicktime
stores those in 'esds' (MPEG-4 audio/video) or 'smi' (Sorensen 1/3)
atoms, matroska stores them in a 'codecprivate' EBML chunk (any).
ASF/AVI have something similar, but store it as an extension to the
stream header inside the same chunk. We use that for WMA audio, for
example.

Now, we don't do much with those right now. We store them into 'flags'
properties in a GstStructure for WMA. For Sorensen, we actually add a
set of flags to GstCaps to read those, but that seems fairly random. For
MPEG-4 audio/video, we don't do anything with it so far (which is a
reason that MPEG-4 video inside quicktime doesn't always decode
correctly with current CVS, I have a sample file on my HD).

So my question is: how will we solve this?

I could add 'flags%d' properties (guint32) to GstCaps for any format
needing those. I could also go for something similar to ffmpeg, called
extradata. I then add a property 'extradata' to GstCaps where needed and
put the binary data as a GstBuffer in there. For mpeg-4 audio, libfaad
accepts a binary array of data as init data, just like ffmpeg does for
mpeg-4 video (as AVCodecContext.extradata). Anyone against me doing
this? Or do you have better ideas?

Ronald

PS yes, this is 0.8.1 material, but I need opinions.




More information about the gstreamer-devel mailing list