[gst-devel] tags and metadata

Thomas Vander Stichele thomas at apestaart.org
Fri Jan 23 06:23:10 CET 2004


El vie, 23-01-2004 a las 14:23, Benjamin Otte escribió:
> On Fri, 23 Jan 2004, Thomas Vander Stichele wrote:
> 
> > Get over it.  You're the only one who thinks it is, and the reason you
> > think so is because it's too hard to get right.  That's fine, but don't
> > call it a bug because of it.  You just don't want to provide anything
> > else than what you think is the One True Way.
> >
> What I want is some defined behaviour so that when someone comes up and
> asks why something doesn't work I know why.

Ok, that's something I can agree with, because I would like the same
thing.

> I'm not against adding that, I'm against not defining it.
> If we define that streaminfo is extracted from the stream and not via
> metadata and that length is streaminfo, I will make id3tag never set the
> length tag..  

length is something what I consider part of the decoded streaminfo - it
is a property of the decoded audio.
I am not sure though if it's something that would be reported through
tags, since currently we do this through querying.

As for the id3 length tag, I think it is a hack/workaround, but I'm not
sure how GStreamer should handle it.  Ideally GStreamer would work well
enough so that it's better to trust GStreamer to get length than id3. 
Note that in practice GStreamer does this pretty well.

But how to handle id3 length tag on the premise that GStreamer is better
at finding it out is harder.  Some people will feel that since it is
indeed part of the id3 spec to have it, they want to be able to edit
it.  Other people would argue that they want the length that the
framework thinks it is, not what joe average set as the length on the
id3 tag.

Since you said you only want one length tag, that's a problem. 
Personally, I think the metadata (ie, editable/tagged) length should be
called length-metadata or somesuch, and the length that can be
calculated through gstreamer should be the default "length" tag.
Alternatively, if the tag hashed not only on name, but on name/type
somehow, that would be fine too.

What I'm getting at is, if I write an app, and I get the length tag
twice (since GStreamer reports it once because it's in the id3 tag and
once because it calculates it, in theory), I would like to prefer the
one from the framework, not the tag, since the framework is supposed to
be more correct.  So I need some way to distinguish between the two.

If the framework doesn't allow me to distinguish them, then I'd prefer
it would not give me the human-changeable one, ie the metadata.

Does that make it more clear from my point of view ?

>  If we agree that streaminfo and metadata are just some
> categories to make it easier for app writers to categorise the tags and
> elements shouldn't care about it, then i'll just set length from id3tag.

Elements care about it since typically the way of reporting them is
completely different.  As an example, metadata of vorbisfile is
retrieved by using vorbistag, and the encoded and decoded streaminfo is
retrieved by using (at this point) vorbisfile.  It will cause some
restructuring of media-info since now I really need different pipelines
for each type of info, while before one plugin signalled everything.

It seems to be similar for mp3, btw.  So it's pretty obvious to me that
plugins detect these different kinds of info in different ways - exactly
because metadata is data tagged onto the stream (mostly in the
container), streaminfo of the encoded stream is encoded inside the
bitstream (typically in headers), and streaminfo of the decoded stream
are the caps properties of the raw decoded audio.

> The only thing that I don't want is "Let's just add something and see what
> it means later".

Ok, so let me know which particular piece of encoded/decoded streaminfo
you are unsure of and I'll clarify.  Afterwards I'll document everything
in the manual.

I hope we can figure out something htat works for all of us and seems
natural both on the app/user and element developer's side.

Thomas

Dave/Dina : future TV today ! - http://www.davedina.org/
<-*- thomas (dot) apestaart (dot) org -*->
Just like you said
you leave my life
I'm better off dead
<-*- thomas (at) apestaart (dot) org -*->
URGent, best radio on the net - 24/7 ! - http://urgent.fm/






More information about the gstreamer-devel mailing list