[haiku] Re: Ogg audio and mimeset

  • From: Axel Dörfler <axeld@xxxxxxxxxxxxxxxx>
  • To: haiku@xxxxxxxxxxxxx
  • Date: Wed, 4 May 2016 09:02:38 +0200

Am 04/05/2016 um 07:21 schrieb Pete Goodeve:

On Tue, May 03, 2016 at 10:16:26AM +0200, Axel Dörfler wrote:
Am 02/05/2016 um 23:27 schrieb pete.goodeve@xxxxxxxxxxxx:
I suspected that might be the case.  Pity.  I suppose there's no
way to prioritize the extension over the rule as they seem to
differ for audio and video?
Sure, each rule gets a score, and the higher score wins. Since Ogg
audio is way more common than video, I'd say audio should have a
higher rating -- although a video player usually also can play
audio, which isn't always the case the other way around.
This doesn't solve the distinction problem, though, does it?  THe
sniffer doesn't seem to pay any attention to the extension, which is
what I was hoping was possible.

No, but I didn't think this was your question :-)
Usually, the extension should be used when there is one. If .ogg (and apparently also .oga) is for audio only, and .ogv for video, we wouldn't really need no fancy sniffer rule.

BTW, I know I've read a description of the sniffer rules in the past
(and thought I had a local copy) but I'm darned if I can find it!
Pointer?  Thanks,

Try this one:
https://api.haiku-os.org/classBMimeType.html#a7e1d370ef1e52b167ac7cee93ca1410e
and:
https://api.haiku-os.org/classBMimeType.html#a0a4dc7205fa52a36a84b9c0b6ed1d904

Unfortunately, it doesn't go into detail how the relationship between file extension and sniffer rule is.

Bye,
   Axel.

Other related posts: