[vorbis-dev] Mime Type and Ogg (More)
Ali Abdin
aliabdin at aucegypt.edu
Thu Oct 19 15:29:54 PDT 2000
* Chris Hanson (cmh at bDistributed.com) wrote at 20:10 on 19/10/00:
> At 10:53 AM +0300 10/19/00, Ali Abdin wrote:
> >On Wed, 18 Oct 2000, Chris Hanson wrote:
> > > "MIME types and MIME magic" are not widely used in modern desktop
> > > apps other than web browsers.
> >
> >They are used in file managers. Nautilus is a file manager. We are trying
> >to get Ogg Vorbis support into Nautilus ;)
>
> What file managers which use "MIME types and MIME magic" are widely
> used on modern desktop systems?
>
> Neither Windows nor Macintosh uses MIME types in their file managers.
> While it's commendable that you want Ogg Vorbis support in an open
> source Unix file manager like Nautilus and I don't want to stand in
> your way, I'd like to point out that the system which you insist
> needs to be supported in a particular way is nowhere *near* "widely
> used" and that this *does* affect your argument.
Doh! Windows uses file extension! my bad. Well, KDE/Konqueror use mime-type! I
believe BeOS uses mime-type, what about MacOS X? Unix in "general" uses
mime-type for some stuff. But whatever.
I am not trying to "bend" or "modify" Ogg Vorbis to support Nautilus' "needs".
I can just listen to people and check for 'vorbis' at offset 29 and that's
that (or I could check offset '0' for 'OggS'). But to be honest, I see a
possible "flaw" in Ogg which I would like to be discussed.
> Besides, it appears that the decision has already been made.
> Nautilus needs to fit in with the rest of the world, not try to bend
> the rest of the world to conform to its vision (particularly where
> its vision is flawed, such as in its assumption that a MIME type or
> an imbedded magic number conveys enough information about a file to
> determine what application to use to launch it).
Whoaaaah! Thats a pretty deep statement. You are basically saying "MIME type"
is useless and apps shouldn't use it to determine a file type.
MIME type is not an invention of Nautilus. You say we are trying to get Ogg
Vorbis to "bend to Nautilus' vision". This is just not true, we are trying to
get Ogg Vorbis to work correctly with mime-type.
If you believe then that an "embedded magic number does not convey enough info
about a file to determine what application to use to launch it" I will
respectfully disagree and say you are WRONG. Mime "magic" tells you the
mime-type of a file and based on that you can launch the application that
handles that mime-type.
For MP3s there is no "embedded magic number" so we have to determine things
algorithmically. If every single file had to use an algorithm to detect its
mime-type there would be several problems:
A) It'd be much slower than the alternative (imagine a directory with hundreds
of file and you have to wait until the mime-types are read using the
algorithms). Note: You could have to run the file through _ALL_ of these
algorithms to determine its mime-type.
B) It would be hell to maintain. It basically means you need to know in-depth
knowledge of the file format to do it.
There are more flaws with the algorithm approach - but I'll leave them for
others to discuss (since I'm not "expert" on mime-type)
I want to clearly point out, I am not debating this for Nautilus' sake - I am
debating this for the Ogg Projects' sake. With Nautilus I can just hack around
it or use 'vorbis' at offset 29.
I honestly believe that the Ogg file format should be able to specify in its
header which file-formats are included within the file. This seems logical to
me.
Say you have a video with audio and text. The presense of video would
indicate that we should launch the "video" application/component/whatever. The
present of just audio alone would indicate that we should play it using the
"audio" application/component/whatever.
Again, this now has nothing specific to do with Nautilus. This is "Ogg and Mime
Magic"
Regards,
Ali
--- >8 ----
List archives: http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'vorbis-dev-request at xiph.org'
containing only the word 'unsubscribe' in the body. No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.
More information about the Vorbis-dev
mailing list