[NUT-devel] FourCC vs format_id

Ivan Kalvachev ikalvachev at gmail.com
Sun Jun 18 14:59:04 CEST 2006

First few word:

Codec identification is actually most important part of the container,
because all other so technically great features are "under the hood".

Fourcc is among the few things that users (even windows one!) are
aware these days .


The real issue is not how we will save and name codecs.
The real issue is how to prevent propagation of existing fourcc
schemes into nut, with all their drawbacks.

What I think we may need:

  format_id - mandatory field. identification of the format, by
standard or bitstream syntax. e.g. "mpeg2","h264","theora", "vorbis".

  profile - optional field. depends on the specifications (e.g. main
simple, etc...). This field informs that full possibilities of the
format are not used.

  encoder - optional. Identifier of the encoder used to create the
stream. Could be used to workaround bugs. Or blame for poor quality.

  fourcc - optional.  Backward compatible code if the format have
such. Same as the file transcoded or one from the "clean list". Used
only by decoders that don't have format_id table.

At first decoders will use only fourcc, because that's what they know.
When nut is widely accepted there will be more decoders that use
format_id, and not fourcc. When other format dies, so will do fourcc.

You may wonder what's the difference between format_id and fourcc.
Think of format_id as trademark. Lusers may load fourcc with all the
crap from avi and qt, but format_id is reserved only for official
standards and bitstreams.

Of course anybody could try to make up new format_id for existing
standards. However giving that there are other means for having clean
separations (profile,encoder), it could not happen by accident.

The profile field is needed to prevent spamming and spawning of new
format_id's for newer versions of the stream (e.g. theroa3.4.12). It
could also be used by hardware players/stream servers to pick up
streams they can play.

The encoder field is the field that is supposed to take all the spam
from the clone codec makers. It should describe exactly the encoder
and to even allow workarounding the know encoder bugs.(e.g. xvid id
and bitstream version that is increased every time encoder bug is
found and fixed)

Even if you don't accept format_id and leave only the fourcc, I would
be happy if you think a little about profile and encoder_id.

More information about the NUT-devel mailing list