[Ffmpeg-devel] 4XM audio codec_tag

Michael Niedermayer michaelni
Mon Nov 6 11:44:17 CET 2006


Hi

On Mon, Nov 06, 2006 at 02:55:14AM +0000, M?ns Rullg?rd wrote:
> Diego Biurrun <diego at biurrun.de> writes:
> 
> > On Mon, Nov 06, 2006 at 02:38:38AM +0100, Michael Niedermayer wrote:
> >> 
> >> On Sun, Nov 05, 2006 at 11:48:08PM +0000, M?ns Rullg?rd wrote:
> >> > Michael Niedermayer <michaelni at gmx.at> writes:
> >> > >
> >> > > i have no problem with one table per format, what i have a problem with
> >> > > is that libav* would fail decoding a file if no match is found and that
> >> > > it would leave the codec tag decission to the end user and not suggest
> >> > > a default one if theres none in the one table for the target format
> >> > >
> >> > > if OTOH there is one table per format and a default fallback table then
> >> > > thats something different with which iam fine
> >> > 
> >> > A "fallback table" doesn't make any sense at all.  None.  Zero.  Nil.
> >> > Either a format supports some particular codec, in which case its ID
> >> > table will have an entry for that codec, or the codec is not
> >> > supported, in which case failure is the only sensible option.
> >> > "Suggesting" to use a tag from some other random format instead is
> >> > utterly senseless.  Such behavior is what created the AVI mess in the
> >> > first place.
> >> 
> >> avi is a generic container its supposed to be possible to store anything
> >> in it (with a few exceptions)
> >> the same is the case for mov, matroska and nut
> >> there is nothing messy with that
> >
> > I was just going to ask that..
> >
> > So please remind me: What is the problem with storing arbitrary
> > audio and video formats in multimedia containers, especially generic
> > ones?
> 
> The format needs to be able to store global headers (aka extradata),
> and it needs some way of identifying the codec.  The extradata part is
> easy: either there is a place for it or there isn't.  If the format
> can't accommodate an extradata chunk, codecs that need it can't be
> used.  To identify the codec, format specifications typically include
> a list of tag/codec pairs.  Any codec in this list can be stored using
> the format in question.  If the codec is not in the list, it is of
> course possible to invent a tag.  The problem with this approach is
> that nobody else will know what this tag means, and thus nobody else
> will be able to play the file.  Is this really so difficult to
> understand?

yes, a codec has a name, and often a fourcc which is used in many
containers, if you use that its not hard to identify it
what you say is like that you would need to make and maintain
a list of all human names per form which contains a field for name
it makes no sense
if i use the fourcc 4xmv, asv1, roq or ... in mov, its clear what
format that is
for a human its clear at once, for a applicaton its clear as soon
as it looks in the common codec_tag table

btw, how does tcvp handle the fourcc <-> codec_id mapping?

[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

In the past you could go to a library and read, borrow or copy any book
Today you'd get arrested for mere telling someone where the library is




More information about the ffmpeg-devel mailing list