Slashdot Mirror


Technical Objections To the Ogg Container Format

E1ven writes "The Ogg container format is being promoted by the Xiph Foundation for use with its Vorbis and Theora codecs. Unfortunately, a number of technical shortcomings in the format render it ill-suited to most, if not all, use cases. This article examines the most severe of these flaws."

79 of 370 comments (clear)

  1. already slashdotted ? by godrik · · Score: 3, Interesting

    I don't see any comment and the website is already down. gg /.

    1. Re:already slashdotted ? by heneon · · Score: 5, Funny

      In related news, I know technical shortcomings in hosting an article on hardwarebug.org...

    2. Re:already slashdotted ? by noidentity · · Score: 4, Funny

      I don't see any comment and the website is already down. gg /.

      Yes, but what format is the website in? I'm thinking something involving ashes.

    3. Re:already slashdotted ? by Jurily · · Score: 5, Funny

      Wasn't us. We don't read the articles before posting.

    4. Re:already slashdotted ? by sopssa · · Score: 4, Insightful

      But there was a lot of interesting points though (I read it before it got slashdotted) and it went to technical points too. But what Ogg support, along others, basically comes down to:

      The third reaction bypasses all technical analysis: Ogg is patent-free, a claim I am not qualified to directly discuss. Assuming it is true, it still does not alter the fact that Ogg is a bad format. Being free from patents does not magically make Ogg a good choice as file format.

      This is so true, not only with Ogg or file formats, but also Linux and open source software too. The patent-free, open source and free are very rarely any good selling points. What it can actually do is. I can only hope more open source developers would get this - you can't sell the idea outside /. people for it being open and free, it also has to be better (or even on the same level).

    5. Re:already slashdotted ? by Nemyst · · Score: 3, Interesting

      Must be a hardware bug.

    6. Re:already slashdotted ? by Yvan256 · · Score: 4, Funny

      There's articles? Since when?!

    7. Re:already slashdotted ? by Steve+Max · · Score: 4, Informative

      However, it's not unique to OGG. AFAIK, MKV is also patent-free, and it's the standard container for torrents^Wprivate-encoded HD video. And it's a much better container anyway.

    8. Re:already slashdotted ? by maxwell+demon · · Score: 2, Funny

      There are articles at the time of submission. They disappear when the summary hits the front page.

      --
      The Tao of math: The numbers you can count are not the real numbers.
    9. Re:already slashdotted ? by Svartalf · · Score: 2, Informative

      If you'd drop the "casual" from the statement, it'd also be fairly accurate.

      I do know that in the large the casual/indie space are using OGG as the format- it's more to avoid the per-unit royalties that the "superior" formats charge, but if it were as all bad as the article author makes it out to be I can assure you that they'd not be using it.

      --
      I am not merely a "consumer" or a "taxpayer". I am a Citizen of the State of Texas
    10. Re:already slashdotted ? by metamatic · · Score: 2, Informative

      AFAIK, MKV is also patent-free, and it's the standard container for torrents^Wprivate-encoded HD video.

      Which is fucking stupid when you think about it. All those MKV files contain MPEG-2, MPEG-4 or h264 video, and usually AAC or MP3 audio. Given that you're using those patent-encumbered codecs, you may as well use the standard patent-encumbered container, MPEG-4. All you do by using MKV instead is annoy people who would like to play the video on their AppleTV, PS3, Mac, PSP, iPod, phone, etc.

      --
      GCHQ Quantum Insert installed. If only our tongues were made of glass, how much more careful we would be when we speak
  2. Still better than AVI by Ltap · · Score: 3, Insightful

    No matter how bad it is, it's still better than AVI. I personally use Matroska, it has all of the ideological benefits (free, non-encumbered, open-source) over stuff like MP4.

    --
    Yet Another Tech Blog
    (but so much more, including game and movie reviews)
    http://yanteb.peasantoid.org
    1. Re:Still better than AVI by Anonymous Coward · · Score: 2, Funny

      You forgot the lack of general support. Definite win on the ideological front.

    2. Re:Still better than AVI by sopssa · · Score: 2, Insightful

      Exactly this. Matroska in general is great and a lot better than Ogg or others, but it doesn't work on any device besides PC - not on 360, not on PS3, not in mobile phones.. CoreCodec should really try to push general support in other devices for it.

    3. Re:Still better than AVI by ObsessiveMathsFreak · · Score: 2, Interesting

      The great thing about Matroska is that it supports (or at least can support) absolutely everything.
      The main drawback of Matroska is that it supports (or at least can support) absolutely everything.

      Matroska is a great container format, but unless you have a program like mplayer or vlc you can't guarantee that a Matroska file is going to be playable on your system. You can't reasonably expect browser maker to standardise on Matroska if it will mean having to include 30+ different codecs in their software, which from a practical standpoint it will. The unfortunate reality is that most of the world's population still doesn't have access to a comprehensive library of software like apt, and while our current software IP regime reigns, they never will.

      --
      May the Maths Be with you!
    4. Re:Still better than AVI by sopssa · · Score: 2, Insightful

      Of course, I use that too. But that's exactly the point - it doesn't support it, so you have to transcode.

    5. Re:Still better than AVI by r_benchley · · Score: 3, Informative

      I use Handbrake http://handbrake.fr/ for encoding. Handbrake will let you chose from MP4 or MKV for container, H.264 or Theora for video and MP3, AAC or Vorbis for audio.

    6. Re:Still better than AVI by Jah-Wren+Ryel · · Score: 3, Informative

      Exactly this. Matroska in general is great and a lot better than Ogg or others, but it doesn't work on any device besides PC - not on 360, not on PS3, not in mobile phones..

      However, matroska support is pretty much standard in any but the most proprietary set-top boxes. For example - WDTV, TiVX, Popcorn Hour - basically anything that uses any recent Sigma Designs chipset. Similarly iRiver supports matroska on their newest portable media players and Archos's latest android based pmp also supports matroska.

      JVC and Phillips have currently shipping blu-ray players that play matroska. Panasonic has announced their next generation of TVs and blu-ray players will do matroska, and the specs for NEC's next gen of video decoder chipsets (which compete with Sigma Designs) say they will include matroska support.

      --
      When information is power, privacy is freedom.
    7. Re:Still better than AVI by Anonymous+Psychopath · · Score: 4, Insightful

      I get what you're saying, but how is this different for Matroska than any other container format?

      --

      Eagles may soar, but weasels don't get sucked into jet engines.

    8. Re:Still better than AVI by jedidiah · · Score: 2, Insightful

      I can see this problem going from MPEG2 to MP4 for an iPhone. So this is hardly a Matroska only problem.

      Consumer video devices, especially video devices, tend to have a very limited range of what they can handle. It's just a side effect of the tech being relatively immature.

      --
      A Pirate and a Puritan look the same on a balance sheet.
  3. Just complaining by Evets · · Score: 4, Insightful

    "I would have done it diffferently" does not mean that the format is bad. None of these "flaws" render the format unusable. Maybe it doesn't perform as well as another format, maybe it isn't designed the way you would like, but it's implemented, it's available, and it's in use.

    1. Re:Just complaining by TheRaven64 · · Score: 4, Interesting
      Wow, did you copy that criticism of TFA from the last section, where he says:

      More commonly, the Ogg proponents will respond with hand-waving arguments best summarised as Ogg isn’t bad, it’s just different. My reply to this assertion is twofold:

      • Being too different is bad. We live in a world where multimedia files come in many varieties, and a decent media player will need to handle the majority of them. Fortunately, most multimedia file formats share some basic traits, and they can easily be processed in the same general framework, the specifics being taken care of at the input stage. A format deviating too far from the standard model becomes problematic.
      • Ogg is bad. When every angle of examination reveals serious flaws, bad is the only fitting description.

      And he's right. Unless the technical details of Ogg are not as he represented them, the format is stupid. I've not looked at Ogg in detail, but I have written multimedia apps and his complaints are right on the mark. Even if most of them are untrue, the point about timestamps would have been a show stopper. There is absolutely no excuse for not encoding timestamps as rationals in a fixed format in the container. Without that, you are just inviting synchronisation problems between audio and video CODEC formats that aren't explicitly designed to work together.

      Which may, of course, be intentional. Vorbis and Theora are designed to work together. But if you have a Theora video stream with MP3 or AAC audio, what happens? An H.264 video stream with Vorbis? Obviously the solution is to just use Xiph formats in the Xiph container. And that's fine. I don't have a problem with Ogg as a container for Xiph formats (other than the latency issues he mentions), but claiming that it is a general purpose format is misleading.

      Ogg is like XML. It defines just enough to let you define something useful, but it's not useful by itself.

      --
      I am TheRaven on Soylent News
    2. Re:Just complaining by sopssa · · Score: 2, Insightful

      Uh, wtf? Just because none of the flaws make it completely unusable doesn't mean it's not bad. If it has serious flaws, it is. As the writer states, it's a complete mess for app developers and lacks some required features that other formats have.

      I can implement, make available and use a format I made in a few hours without thinking about it. Maybe it misses features for seeking because I didn't think about adding timestamps, and probably only usable audio format is WAV. But in your words it doesn't make my container bad and anyone criticizing it would be just complaining.

    3. Re:Just complaining by Aladrin · · Score: 2, Insightful

      Actually, they never said 'unusable'. They said 'ill-suited'. And it is, if their technical objections are all correct.

      It sounds like Ogg tried to be too much and as with any over-generalization, the specifics suffer for it.

      That doesn't mean it should't be used, it just means it's not optimal.

      --
      "If you make people think they're thinking, they'll love you; But if you really make them think, they'll hate you." - DM
    4. Re:Just complaining by Wildfire+Darkstar · · Score: 3, Informative

      Haven't read the article, because it's slashdoted, but I assume it's about the fact that the Ogg container was initially designed as a transport stream format for audio.

      The article goes considerably beyond that, arguing that the container is flawed even as an audio format. Here's the money quote (emphasis mine):

      When challenged, [Ogg campaigners] will occasionally assume an apologetic tone, explaining how Ogg was only ever designed for simple audio-only streams (ignoring it is as bad for these as for anything), and this is no doubt true. Why then, I ask again, do they continue to tout Ogg as the one-size-fits-all solution they already admitted it is not?

      --
      Sean Daugherty "I have walked in Eternity -- and Eternity weeps."
    5. Re:Just complaining by evilviper · · Score: 2, Interesting

      "I would have done it diffferently" does not mean that the format is bad.

      Every open source multimedia developer outside of Xiph.org, who has had to do anything with Ogg, will tell you that Ogg is a flaming pile of crap. This notably includes Moritz Bunkus, the author of Ogmtools. Quotes of such are easy to find.

      For a real challenge, just try to find ANYONE saying Ogg is a well-deigned and well thought-out container format...

      --
      Slashdot gets worse every day... Pipedot: News for nerds, without the corporate slant
    6. Re:Just complaining by arose · · Score: 2
      Since people keep bringing up Matroska as a well designed coded we could see what they say about Ogg:

      It's less a matter of better/worse, and more a matter of different. This is a little complex but we will try ad explain.

      and

      Will Matroska be streamable? Yes, but low bitrate streaming like streaming Vorbis, will always be better in Ogg. This is because their design is for different purposes.

      Are we to believe that they have no clue about container formats?

      --
      Analogies don't equal equalities, they are merely somewhat analogous.
    7. Re:Just complaining by evilviper · · Score: 2, Interesting

      Are we to believe that they have no clue about container formats?

      YES! From the same link:
      Ogg was designed to stream audio, specifically Vorbis. Ogg was not designed to handle video, or any other type of audio.

      Ogg is so tightly coupled to Vorbis, and has only the minimal features required for streaming. It's shortcomings become clear when you try to do ANYTHING ELSE. Even just playing a local file, you find seeking horrible, no way to do a accurate progress-bar, etc, etc.

      And when you try to stick anything else in an Ogg, forget it... Even Theora. It's a mess. Wonder why it took so many years after VP3 went open source before Theora-1.0 was released? A big chunk of time was spent squeezing it into an Ogg. Meanwhile, every other container had no problem holding VP3 video.

      --
      Slashdot gets worse every day... Pipedot: News for nerds, without the corporate slant
  4. Not a selling point by XanC · · Score: 3, Insightful

    It's not a selling point, it's a starting point. It's a sine qua non. For an application like video on the Web, nothing non-free can even enter the conversation.

    1. Re:Not a selling point by Lunix+Nutcase · · Score: 4, Insightful

      Apparently the rest of the world disagrees considering the widespread nature of flash video that has always used proprietary audio and video codecs.

    2. Re:Not a selling point by maxume · · Score: 5, Insightful

      And then over here in actuality (rather than the conversation), there is Youtube. And Netflix. And Hulu. And so on.

      --
      Nerd rage is the funniest rage.
    3. Re:Not a selling point by Locke2005 · · Score: 2, Informative

      Unfortunately, it can enter the conversation. Standards should be free, open, and unencumbered to allow for rapid adoption. That doesn't mean they always are. For example, Microsoft, simply because of it's size, can drive a non-open standard into widespread adoption (this isn't always a bad thing.)

      --
      I've abandoned my search for truth; now I'm just looking for some useful delusions.
    4. Re:Not a selling point by egamma · · Score: 5, Insightful

      It's not a selling point, it's a starting point. It's a sine qua non. For an application like video on the Web, nothing non-free can even enter the conversation.

      Says who? XanC? Any format (and its software requirements) can succeed as long as the users will put up with it.

      RealPlayer did very well for many years (say 1995-2000).
      Apple Quicktime is used on many sites.
      And of course, there's Adobe Flash.
      To simply say that "nothing non-free can even enter the conversation" is ridiculous. Are your clothes free or open source? Your car? Your house? Your shampoo, your radio, your computer's processor, your keyboard?

      Companies can make excellent closed-source products. Communities can make excellent open-source products.

    5. Re:Not a selling point by maxume · · Score: 2, Insightful

      In which case the standard will be impotent (because it will be completely divorced from practice).

      --
      Nerd rage is the funniest rage.
    6. Re:Not a selling point by aflag · · Score: 2, Interesting

      However, do you disagree? Why? I hope it's not because of this world you talk about.

    7. Re:Not a selling point by drtsystems · · Score: 2, Interesting

      This argument is what will kill HTML5 and ensure a new era of the reign of flash, silverlight, etc. The choices are not h264 or theora. Its h.264 through an open html5 spec, or h264 through silverlight and flash. All major operating systems have support for h264 built in as it is (not to mention all the portable devices with hardware acceleration for it, including now many netbooks). The whole debate is stupid, firefox needs to just use the operating system's built in codecs to play h264. Problem solved.

    8. Re:Not a selling point by vadim_t · · Score: 4, Insightful

      Says who? XanC?

      Add me to that list

      Any format (and its software requirements) can succeed as long as the users will put up with it.

      It can, yes. But there's a difference between what can be done, and what should be done.

      And of course, there's Adobe Flash.

      Actually, as of recently the Flash spec is available without restrictions, and there's gnash, a GNU implementation.

      To simply say that "nothing non-free can even enter the conversation" is ridiculous. Are your clothes free or open source? Your car? Your house? Your shampoo, your radio, your computer's processor, your keyboard?

      No, but I think they should be, it'd be better if they were, and that it's a goal well worth fighting for.

      Especially since we're talking about standards here, and I don't see how something with one possible implementation can be a standard. A standard is a published spec anybody can implement. "Buy from $company" isn't a standard.

      Actually, I think you used quite horrible examples as well. Let's see:

      Clothes: the "spec" is open. Anybody can make their own pants if they wish to, and nobody is going to come ask for license money.
      Car: Also open and well documented.
      House: Built according to code
      Shampoo: has a very loose open spec
      Radio: How to receive FM signals is well documented and not restricted AFAIK
      CPU: some (though not all) are open, with complete specs and source available
      Keyboard: Either PS/2 or USB, is made to fulfill an open specification.

      Every single thing you picked as an example complies with an open standard, can be made by anybody without needing to pay for a license, and is interoperable (any car from any manufacturer works and is legal to drive, so long it complies with the relevant standards for instance)

      Companies can make excellent closed-source products. Communities can make excellent open-source products.

      It's not about the quality. It's about a principle. I reject a closed "standard" for web video on principle, no matter how well implemented.

    9. Re:Not a selling point by sopssa · · Score: 3, Insightful

      And of course, there's Adobe Flash.

      Actually, as of recently the Flash spec is available without restrictions

      But Flash still uses H.264 too. I don't see too many people, either normal web users, webmasters or those making Flash applets complaining.

      It's good you reject closed-source products by principles, I wish I would too. But the reality is, people just want the best performing tool for the job and frankly the older I get the more I think so too. I had these fundamentalist ideas in late teen years, but then I faced the real world. Now I pick the right tool for the job, be it open source or closed. I use Windows on desktop because I game and think the experience is better, while still giving me freedom to mess around with the system. I use Linux on servers because they perform a lot better and command line usage with servers is a lot better, and in that case and scriptability Windows doesn't come even close. But fundamentalism and closed mindset in the end is just stupid.

    10. Re:Not a selling point by drooling-dog · · Score: 3, Insightful

      Mindshare has more to do with advertising and promotion than raw technical superiority. Proprietary, patent-protected technologies tend to florish simply because companies are more willing to invest in promoting them if they'll reap all of the benefits when they sell. If anyone and her brother could legally make and sell Gucci-branded handbags, then there would be no incentive for Gucci to spend $millions on advertising and you'd likely never hear about them.

    11. Re:Not a selling point by interval1066 · · Score: 3, Insightful

      Apparently the rest of the world disagrees considering the widespread nature of flash video that has always used proprietary audio and video codecs.

      And that will be fine so long as Adobe is always around to maintain and develop Flash, and people are always willing to use it. Personally, I can't see being married to one av format simply because it works, world opinion be damned, but it is what everyone uses. Until HTML 5 gets wider adoption, perhaps. Frankly, if I were Adoba I'd be getting out of the "Chief bottle washer and Flash maintainer" business myself, I hope for their sake they've poured money into something new that they've kept the wraps on, as I would hate to have as large a percentage of my business as they have based on 15 year old technology. I'd do that then just before I trotted the new stuff out let Flash wander out into the open source pasture.

      --
      Python: 'And then suddenly you have a language which says "we're all stuck with whatever the whiniest coder wants".'
    12. Re:Not a selling point by vadim_t · · Score: 3, Insightful

      But Flash still uses H.264 too. I don't see too many people, either normal web users, webmasters or those making Flash applets complaining.

      For now. Just wait until they decide to start charging for the license, then there will be plenty to complain about, but it'll be hard to avoid paying up, since it will be so widely used.

      It's good you reject closed-source products by principles, I wish I would too. But the reality is, people just want the best performing tool for the job and frankly the older I get the more I think so too.

      People are short sighted. I think long term.

      I had these fundamentalist ideas in late teen years, but then I faced the real world. Now I pick the right tool for the job, be it open source or closed.

      I had these ideas in late teen years, but then I faced the real world. I worked with proprietary stuff enough to figure out that indeed I don't like it, so I got a job where I work exclusively with Open Source and release my code under the GPL. It's really awesome, you should try it.

      I use Windows on desktop because I game and think the experience is better, while still giving me freedom to mess around with the system.

      I use Linux on the desktop because that's what works best for me -- though for me "works" nearly implies "comes with source". Even if it works now, some day it'll do something I don't want it to, or not do something I want it to. That's why I require the source upfront, then I don't have that issue.

      I use Linux on servers because they perform a lot better and command line usage with servers is a lot better, and in that case and scriptability Windows doesn't come even close.

      I use Linux on servers for the same reason.

      But fundamentalism and closed mindset in the end is just stupid.

      It's not fundamentalism, it's long term thinking. I don't like exchanging short term convenience for lock-in, licensing payments and major limitations later.

      And as the time passes, OSS software improves so things keep getting better. Maybe you should give it another try.

    13. Re:Not a selling point by jedidiah · · Score: 3, Insightful

      The rest of the world has always constantly complained about how buggy and slow Flash is. Even the HONEST "boosters" have freely admit to this problem. This is a problem that exists primarily because of the very proprietary nature of Flash. Although this does demonstrate how patents alone aren't such a barrier. EVERYONE has better video implementations than Adobe. This even includes multiple Linux video players.

      There are $200 general purpose PCs that make great little HTPC machines except for one little detail: Adobe's a sandbagger.

      This comes from letting crass corporations have the keys to the kingdom.

      --
      A Pirate and a Puritan look the same on a balance sheet.
    14. Re:Not a selling point by Korin43 · · Score: 2, Interesting

      As opposed to a standard that you can't standardize on (because only Google can afford the licensing fees). They're pushing back when the fees start, but that doesn't change the fact that small businesses and individual people would have to be insane to start a website using H.264.

    15. Re:Not a selling point by VGPowerlord · · Score: 4, Insightful

      PNG gained support for three reasons.

      1. It's non-lossy, unlike JPG.
      2. It's does 24-bit color with 8-bit alpha transparency, unlike GIF which does 8-bit color with indexed transparency (one color is replaced with transparent).
      3. Unisys patent trolled companies/people who made image editors that could output GIF.

      --
      GLaDOS for President 2016! "Well here we are again. It's always such a pleasure." -- GLaDOS, 2011
    16. Re:Not a selling point by hairyfeet · · Score: 4, Insightful

      I would say it is more because they work than any adverts. Take H264 as an example. Even on the lowest cost machines I build there is hardware acceleration out of the box for H26x, WMV 7-9, DivX, and MPEG 2 (and usually 4). This makes those formats much nicer to use, their playback much smoother, and the overall hardware more responsive because the CPU isn't bogged down with playback. In short it works.

      The average Joe really doesn't give a shit about "free as in freedom" all he gives a shit about is does it work and is it easy. That is why MP3 stomped Vorbis and FLAC, because it was easy (most of the files they downloaded/ripped were MP3 and every device supported it) and it worked (MP3 playback gave longer battery life over WMV, can't say about Vorbis as I've honestly never come across a Vorbis player) so they were happy little campers. As for website builders, if site A has H264 and gives me a great experience on my netbook/cell phone/etc and your site uses Theora and runs like shit? Well I'm not likely to return to your site now, am I?

      The problem with the OGG formats is the classic "chicken or the egg" problem. Nearly no support in hardware, doesn't work as well as established formats (thanks to hardware acceleration) and the average Joe really doesn't care whether a format has patents up the wazoo or not as long as it works for him, which considering like the other 90% he is probably using Windows or a cell phone/PMP with H264 acceleration it does. Sadly while I hoped that Theora might be the fabled "flash killer" I'm predicting it will be just like Vorbis, a niche format that almost nobody ever uses. Everywhere I go I see "H264 support" on hardware, I don't think there even IS a single device with hardware Theora support, is there? OGG being "free as in freedom" really isn't gonna matter much if nobody supports it, and I haven't seen hardware manufacturers rushing to add it to their bullet point lists.

      --
      ACs don't waste your time replying, your posts are never seen by me.
    17. Re:Not a selling point by horza · · Score: 2, Interesting

      "That is why MP3 stomped Vorbis and FLAC, because it was easy"

      Because it was first, and gained momentum. At the end of the day, MP3 gained popularity because of pirates and they aren't exactly known for caring about patents. Those that were ripping from their personal collection often chose FLAC or Vorbis. A codec is just a codec, there is nothing more 'easy' about any one of them.

      "can't say about Vorbis as I've honestly never come across a Vorbis player"

      Any Samsung player, but then if Vorbis became popular it would only take a firmware update for every player to support it.

      "The average Joe really doesn't give a shit about "free as in freedom" all he gives a shit about is does it work and is it easy."

      I'm sorry, why do I care about average Joe? If he is prepared to fork out hundreds for XP, then again for Vista, then again for Win7, etc, why would I care if he forks out for yet another bunch of proprietary rubbish? However, on the distribution side things are different. An Internet 'video tax' is unacceptable.

      Phillip.

    18. Re:Not a selling point by Risen888 · · Score: 4, Insightful

      MP3 playback gave longer battery life over WMV, can't say about Vorbis as I've honestly never come across a Vorbis player...

      The problem with the OGG formats is the classic "chicken or the egg" problem. Nearly no support in hardware...

      I don't think there even IS a single device with hardware Theora support, is there? OGG being "free as in freedom" really isn't gonna matter much if nobody supports it, and I haven't seen hardware manufacturers rushing to add it to their bullet point lists.

      You lose all credibility with nonsense like this. My Sansa Fuze plays ogg (flac too, but anyone who puts flac files on a 4gb flash device is taking it a little far). My dear departed iAudio X5 played ogg and flac. A fucking shitload of audio players play ogg. Go ahead, ask me why.

      "Why, Risen?"

      I'll tell you why. Because it's patent-free, unencumbered, and an easy bulletlist item to put on a device. No, maybe they "don't give a shit about freedom," but they do give a shit about easy.

      --
      Hey, I finally got my first freak! Took you long enough!
    19. Re:Not a selling point by mabhatter654 · · Score: 2, Insightful

      but OGG is here, OGG is now, and OGG is part of the spec.. until a bunch of whiners decided they didn't want FREE competition. Ogg may not be great, but it's "good enough". There are many "standards" web browsers support that haven't been used on modern pages for ages.

      The article completely misses the point that Ogg would be just fine for the little snips from my iPod Nano, or from my little hand recorder, or for my SCA how-to videos. The day is coming when people will have to PAY to host all these popular video and audio formats on their own sites. With the new IP rules coming ISPs will be forced to lock out anybody that doesn't pay first.. there's no "fair use" for patents. Meaning you will be forced to pay a large fee, or host ALL your material thru Apple or Google (and force your visitors to watch THEIR ads) who will have a choke-hold on everything interesting on the Internet.

    20. Re:Not a selling point by buzzn · · Score: 2, Insightful

      "The rest of the world has always constantly complained about how buggy and slow Flash is. Even the HONEST "boosters" have freely admit to this problem. This is a problem that exists primarily because of the very proprietary nature of Flash."

      Um, no. Being proprietary does not inherently make one slow or buggy, and being open-source does not make anyone faster or less buggy. If you believe so, I have a bridge to sell you.

      Flash is "slow" if for any reason, because it is cross platform and tries to do a lot of things, including gaming, RIAs, and video, etc, and is immensely ambitious (trying to run on any number of phones as well as desktops), and yes has an aging code base. These are not problems inherent to proprietary software.

      You may say that a rewrite from scratch might help, but then you'd also need an economic incentive to cause people to invest the time and effort to do so, and you'd also be opening all sorts of intellectual property issues, plus what about the tools necessary to support workflows, etc. Merely complaining about the status quo, without suggestions, is not a good solution.

      --
      Join the window installer's union, where prosperity is a brick throw away!
    21. Re:Not a selling point by adolf · · Score: 2, Informative

      Netscape Navigator had useful support for PNG starting in November, 1997 with version 4.04. This beat even the existence of Firefox 1.0 by seven entire years.

      This was even several months before Netscape released the source code for their browser, which was the event that made Firefox possible in the first place.

      Even Microsoft had the beginning of useful PNG support in Internet Explorer starting with version 4.0, released in September of 1997.

      Now, sure: As I recall, Firefox was way before IE in fully supporting all of the features of PNG. But to say that it supported PNG before IE, when IE supported PNG before Firefox could even have begun to exist, is a little anachronistic.

    22. Re:Not a selling point by moonbender · · Score: 2, Interesting

      You care about the average Joe because he seemingly gets to decide which codec is hardware accelerated and which codec is used by major web sites. Even if you (or I) find his choice unacceptable.

      --
      Switch back to Slashdot's D1 system.
    23. Re:Not a selling point by peppepz · · Score: 2, Interesting

      You care about the average Joe because he seemingly gets to decide which codec is hardware accelerated

      Yes but "hardware acceleration" means cheap devices which only play media when encoded with certain codecs, only at some bitrates, only at certain resolutions and colour depths, and only when in certains containers: all of this, together with obscure, unfixable hardware bugs which result in defective playback when the media was encoded a hair differently from the streams the device was tested on.

      I suppose fixed function decoders can be power efficient, but before my battery life, I care about a device that DOES play my stuff. Usually you can't know the details of the media supported by a device before buying it, because its box will probably read "plays h.264" instead of "plays h.264 baseline profile only, with resolutions from 128x128 to 512x512 and a framerate multiple of 16".

      The right thing to do for video acceleration is to extend CPUs (GPUs, DSPs) instruction sets in order to provide general acceleration for any kind of media. This is perfectly possible with today's devices (my 2006 phone plays PAL-encoded DivX movies just fine, without any assistance from its manufacturer). Fixed function hardware is a thing of the past.

  5. Flawed reasoning... by Anonymous Coward · · Score: 3, Insightful

    There's at least one obvious flaw in his reasoning. He talks about removing the 8-bit version field in the header and replacing that with a 1-bit portion of the flags field to distinguish it from a hypothetical future version. That only works if one assumes there will only *ever* be two versions (v1 and v2). Such a basic failing of analysis is a pretty good indicator that he hasn't thought it all through as completely as he thinks he has.

    1. Re:Flawed reasoning... by sylvandb · · Score: 2, Interesting

      There's at least one obvious flaw in his reasoning. He talks about removing the 8-bit version field in the header and replacing that with a 1-bit portion of the flags field to distinguish it from a hypothetical future version. That only works if one assumes there will only *ever* be two versions (v1 and v2).

      No, the flaw is yours. The 1 bit merely says "this is not the original version" and anyone that only knows the original version just stops there. Anyone that knows the 2nd version has enough smarts to look at the 2nd version bit (or field).

    2. Re:Flawed reasoning... by Josef+Meixner · · Score: 4, Insightful

      It is not in the header, the 8-bit version field is in every single page. As according to the post a page is mostly 64K due to a strange length encoding, you send the version very, very often. I don't see any reason, why the version would have to change in the middle of a file in any case. And honestly, would you write a decoder taking that into account, if the probability of stumbling onto such a file was currently 0 (due to there being only one version) and very, very low in the future? That means it just adds to the size of the file.

      The second reason is even simpler, you only need one bit to tell the current format from the future formats. As there hopefully will be a good reason for a future version the page header will probably be different, so I can add a version field there when I at least found one reason why I need it, no? That way I need one bit now and can still have different versions later.

    3. Re:Flawed reasoning... by Yokaze · · Score: 3, Informative

      > I don't see any reason, why the version would have to change in the middle of a file in any case.

      It is probably not due to the fact, that the version might change in the middle of the file, but in case, you only have a part of the file.
      This makes it more robust, and better suitable for streaming: You can simply start sending from an arbitrary position, and the parser should
      be able to recover at some point.

      --
      "Between strong and weak, between rich and poor [...], it is freedom which oppresses and the law which sets free"
    4. Re:Flawed reasoning... by 0xABADC0DA · · Score: 3, Informative

      No, the flaw is yours. The 1 bit merely says "this is not the original version" and anyone that only knows the original version just stops there. Anyone that knows the 2nd version has enough smarts to look at the 2nd version bit (or field).

      In which case once there is a second version you have the exact same packet format as the current ogg, except for an extra mask, test, and one fewer flag bit. So the only gain at all is if you assume there will never be another version, and if there is even one more version then you've caused a pipeline stall for no reason. Which is stupid.

      This goes along with the criticism of the checksum field as 'wasted space', but it is probably put there so you can reliably find the page header if doing a random seek. Which if you can do, then you don't need a time index because you can do a binary search to find any time index with only a tiny bit of extra seeks.

      I haven't looked at these formats in depth, but it sure sounds like this guy is clueless.

    5. Re:Flawed reasoning... by logicnazi · · Score: 2

      No, that's not true. Version 2 can simply define a new bit to indicate whether it's version 2 or later.

      The real problem with this optimization is it's effect on later versions.

      Say one eventually moves to version 12 and each version along the way defines it's own flag. That mean's you've used 12 bits and some very nasty decoding logic to indicate you are a version 12 format when you could have just reserved that one byte and used a case statement.

      I mean the annoyance and difficulties created by using a next version flag (and the poor scaling behavior with higher version numbers) is a high price to pay to save a couple bytes in a multimedia codec.

      --

      If you liked this thought maybe you would find my blog nice too:

  6. what is the point, exactly. by theheadlessrabbit · · Score: 4, Insightful

    I'm not an expert in video or audio production, I just dabble in it as a hobby. but one thing I often wonder is, what is the point of these container formats?

    I've got a miniDV camera, and a canon point and shoot that thanks to chdk can record good-enough video. Both give me ".AVI" files, even though one is miniDV, while the other is Mjpeg. Mjpeg files don't work in my editor, while miniDV does. but I didn't know this at first, all I knew was that I have a bunch of .AVI files sitting in my hard drive, some work, some don't. I dont care about file extensions, I care about having files that work. I care about codecs. If they were named "filename.minidv" and "filename.mjpg" that information would be useful to me. What good is a container format when only half of the files within that container will play on my system?
    I'm not trying to knock the idea of container formats, if they exist, their must be some beneficial reason for them. Could someone please enlighten me on what that reason is?

    --
    -I only code in BASIC.-
    1. Re:what is the point, exactly. by Dragoniz3r · · Score: 5, Informative

      Because, in general, you don't only want a video stream. You want to be able to bundle multiple streams together (usually of different types, eg an audio stream and a video stream). Vorbis, for example, is audio. Theora would be video. Ogg (the container) exists to bundle them together into a single file, so you can have a movie and sound with it.

    2. Re:what is the point, exactly. by Anonymous Coward · · Score: 4, Informative

      I'm not an expert in video or audio production, I just dabble in it as a hobby. but one thing I often wonder is, what is the point of these container formats?

      The point of containers is to make the contained media modular. This way, you can assemble a multimedia ("many media"... whodathunkit) file from several individual pieces of media, each with codecs that may or may not be on speaking terms, into a cohesive file that i played as a unit.

      If you define a format that has a video track and two channels of audio, you might think, hey, that's great, and play stuff on your computer. But what if you want a 5.1 audio track? Make another format, one for stereo and one for 5.1. Second audio program, like an alternate language? More formats: one for stereo + stereo SAP, one for 5.1 main + stereo SAP, one for 5.1 both; up to 5 formats now. Subtitles or closed captioning? More formats: up to 20 now. A different audio codec? Even assuming the SAP tracks and main use the same codec (they might not; depends on where you got the SAP track from), add 20 formats per audio codec. Multiple video codecs? The number of formats can grow exponentially. And we haven't even gotten to things like multiple camera angles and sideband info like text commentary, HTML links to things discussed in the show, or TV listings.

      Or you can define a container and then, in each of those cases, only need to define a new component to be put into the container, and you're done. Containers make things much simpler and easier to implement.

    3. Re:what is the point, exactly. by reacocard · · Score: 2, Insightful

      But its not just one codec that's involved, it's multiple. A typical video file will have at least two, one for video, one for audio. If you have alternate audio streams or subtitles, you need a codec for each of those as well. The purpose of a container is to let you take all these streams in their individual codecs and put them together in one file for easy playback. I'll grant you that it's not optimal to have some files with a given extension playable and some not, but with such a multitude of codecs in a single file it's just not possible to condense all that information down to a single file extension.

    4. Re:what is the point, exactly. by cheesybagel · · Score: 2, Informative
      Code reusability. You can use an MPEG-4, MPEG-2, or MPEG video codec with the same MP3 audio codec. The integration parts of the code can be reused as well. Forward compatibility: you can easily make a library so programs can use the same API to decode a variety of codecs. This means a program can support file formats which did not exist when it was written.

      Of course this is mostly true for player software. Editing software sometimes wants to do more low level bit twiddling (e.g. to minimize recompression) and accesses the files in a more direct fashion, bypassing the standard OS APIs. It is also likely your programs use different OS media APIs. Windows has like two different APIs: VfW, DirectShow. There are also some apps that use the Quicktime API.

  7. In the long run by istartedi · · Score: 4, Interesting

    "In the long run, all file formats become programming languages."

    From this I draw a number of conclusions, the first being that when designing a format you need to bring a "language sensibility" to it. If you don't, it's only a question of *when*, not if, your format will become a poorly designed language. OK, "language" may not be the right word. I'd also accept, "byte code" or "executable file", but it's the same idea. JMHO.

    --
    For all intensive purposes, "whom" is no longer a word. That begs the question, "who cares"?
  8. Which doesn't answer the question ... by ITMagic · · Score: 2, Insightful

    ... of what format *should* be used in its place.

    It is all very well claiming one format is not particularly good, but overall rather pointless if you don't argue an alternative.

    So the question any .ogg user will have (since they probably chose this slightly obscure format over the more 'normal' .mp3 alternative due to the reputation of being better to listen to from an audiophile POV) is what to use instead? FLAC is fine if you have the space, but sometimes you want to compromise in order to save storage space...

  9. Re:Ogg is a nice format by Anonymous+Psychopath · · Score: 4, Insightful

    I can't say anything about video, but for audio all my CD collection is converted to Ogg instead of MP3, you can't even spot the difference in quality, thou the filesize is smaller. BTW, my MP3 player supports Ogg playing as well.

    Audio quality and compression efficiency are controlled by the codec, not the container format. The article is critiquing the latter.

    --

    Eagles may soar, but weasels don't get sucked into jet engines.

  10. Technical Objections by Armchair Engineer? by guruevi · · Score: 2, Insightful

    His complaints:

    On top of this we have the 27-byte page header which, although paling in comparison to the packet size encoding, is still much larger than necessary.
    Ok, it's a container format, nobody cares about an extra 27 bytes when you can buy TB of storage for virtually nothing. And if you're complaining because it needs to go in the intertubes, gz compression on the server does a very good job of extracting and compressing plain non-random text like page headers but again, MBits are cheap and unless you're living in the US they are plenty.

    The version field could be disposed of, a single-bit marker being adequate to separate this first version from hypothetical future versions. One of the unused positions in the flags field could be used for this purpose
    It's kind of important to keep track of versions. If your player can't play the next version or an older version it should be able to detect that so it doesn't try-and-fail. It might also want to suggest what version of the player is required.

    A 64-bit granule_position is completely overkill. 32 bits would be more than enough for the vast majority of use cases. In extreme cases, a one-bit flag could be used to signal an extended timestamp field.
    That's what they said about our memory too back in the early 90's. 32-bit addressing is enough, nobody will ever have more than 4G of RAM. Again, these open formats tend to be scalable across time because they need to fulfill a certain mission. Look at ZFS, they have 128-bit addressing but nobody (currently) needs that amount of storage.

    32-bit elementary stream number? Are they anticipating files with four billion elementary streams? An eight-bit field, if not smaller, would seem more appropriate here.
    Why not, how many languages are there around the world? If you need to bring out a media file with subtitles and audio-tracks for each language, braille instructions and who knows what else for open access to certain media, you might want to use more than 256 streams.

    The 32-bit page_sequence_number is inexplicable. The intent is to allow detection of page loss due to transmission errors. ISO MPEG-TS uses a 4-bit counter per 188-byte packet for this purpose, and that format is used where packet loss actually happens, unlike any use of Ogg to date.
    Well, maybe the makers intended Ogg to be used eventually to replace MPEG (c)(patented) and used across links with much higher transmission errors. Sometimes my MPEG-encoded stream I get from my DTV provider has enough errors to stall and cause artifacts. When NASA wants to use Ogg for a non-repeatable stream from outer space, they should be able to. Again, overhead is a small cost to pay these days.

    A mandatory 32-bit checksum is nothing but a waste of space when using a reliable storage/transmission medium. Again, a flag could be used to signal the presence of an optional checksum field
    Ah, well, what is reliable these days? Ever used a large array of hard drives? Ever used a freakin' dial-up connection? As the makers of ZFS, Google and a few others recently have shown hard drive and memory reliability is not as good as we take for granted. Silent data corruption is a major cause of data loss these days.

    With the changes suggested above, the page header would shrink from 27 bytes to 12 bytes in size.
    Whoop-dee-doo, you made it half the size but you sacrificed reliability, error correction and future-proofness.

    Latency
    You show that the overhead is anywhere from 1% to 7%. That might not be the requirements for latency-sensitive applications but then you would again sacrifice other features. That is always a balance between speed and reliability but for most applications it doesn't really matter if the movie needs to be buffered 5ms longer.

    Random access
    You've got somewhat of a point there, maybe somebody will find a solution for that. The issues around indexing however is that seeking within a stream is possible. HTTP servers

    --
    Custom electronics and digital signage for your business: www.evcircuits.com
    1. Re:Technical Objections by Armchair Engineer? by bbn · · Score: 2, Interesting

      Random access
      You've got somewhat of a point there, maybe somebody will find a solution for that. The issues around indexing however is that seeking within a stream is possible. HTTP servers allow you to start/stop downloading from different points in time and QuickTime is one of those formats that uses this feature.

      He is trying too hard make an issue out of it. Read this:

      In a large file (sizes upwards of 10 GB are common), 50 seeks might be required to find the correct position.

      A typical hard drive has an average seek time of roughly 10 ms, giving a total time for the seek operation of around 500 ms, an annoyingly long time.

      Now being a binary search, each seek halves the size of the search domain. The minimum size a harddrive can read is 512 bytes, so there will be no further seeks after we find a search domain less than that.

      So 50 seeks is only needed with a filesize of 512 * 2^50 = 576460 terabytes.

      For a 10 GB file you would need no more than half that many seeks (25). Take into account that most filesystems do not distribute the file at random over the whole harddrive, which makes the average seek time for the file much smaller than 10 ms. We are probably looking at no more than 100 ms to do this random access search on a 10 GB file.

      100 ms might still be enough to complain about. But he is not making his point stronger by exaggerating the problem.

    2. Re:Technical Objections by Armchair Engineer? by bbn · · Score: 4, Insightful

      I forgot to mention that one can do much better than a naive binary search. Read the first and the last of the file to calculate the average block size. Calculate the approximately place your target will be. Jump there and repeat. Once you are very close to your target, read a larger block of data which will get your target by a very large probability.

      This would get your target with not many more seeks than reading an index.

    3. Re:Technical Objections by Armchair Engineer? by pslam · · Score: 5, Interesting

      Your objective is to Armchair engineers? Ok, well I'm not an armchair engineer. I've written my own Ogg/Vorbis decoder from scratch in the past (here). I've worked on codecs for about 10 years. I'm a fan of Vorbis and Theora, but Ogg needs to die a horrible death.

      Ogg was by far the most bug-inducing part of the code. It's just AWFUL. It's ill-designed. It's incredibly complicated. It's inherently inefficient (copy sometimes required).

      In short, it's the worst container format I've used in any serious application, and I've used pretty much all the common ones.

      The irony of what you're saying, is that actually Ogg is what you'd end up with if an armchair engineer designed an audio codec container from scratch.

    4. Re:Technical Objections by Armchair Engineer? by shutdown+-p+now · · Score: 2, Insightful

      I wonder who's the armchair engineer here...

      Ok, it's a container format, nobody cares about an extra 27 bytes when you can buy TB of storage for virtually nothing.

      It's extra 27 bytes per page, not per total file. "Tb of storage" reference is irrelevant, since we're talking about streaming here.

      And if you're complaining because it needs to go in the intertubes, gz compression on the server does a very good job of extracting and compressing plain non-random text like page headers

      Are you seriously proposing live streaming the entire an audio or video stream (presumably produced by a compressing, lossy codec) through gzip?...

      Or did you suggest just running gzip on the headers? In the latter case, you do realize that the overhead will likely be larger than header size?

      It's kind of important to keep track of versions. If your player can't play the next version or an older version it should be able to detect that so it doesn't try-and-fail. It might also want to suggest what version of the player is required.

      TFA doesn't say that it's not important. It says that there are more space-efficient ways of doing so, especially when there is only a single container version so far in practice (so we may just as well optimize for this case).

      That's what they said about our memory too back in the early 90's. 32-bit addressing is enough, nobody will ever have more than 4G of RAM. Again, these open formats tend to be scalable across time because they need to fulfill a certain mission. Look at ZFS, they have 128-bit addressing but nobody (currently) needs that amount of storage.

      Again, TFA does say that, for those extremely rare cases where 64-bit positions would be needed, a more efficient variable-length encoding could be devised, so that the common case is smaller (e.g. 31 bits lower + 1 bit flag + optional 32 bits upper).

      Why not, how many languages are there around the world? If you need to bring out a media file with subtitles and audio-tracks for each language, braille instructions and who knows what else for open access to certain media, you might want to use more than 256 streams.

      I can actually agree on the reasoning here, but again, there are more efficient ways to encode a number of "usually less than 16, very unlikely but still possibly hundreds".

      Well, maybe the makers intended Ogg to be used eventually to replace MPEG (c)(patented) and used across links with much higher transmission errors. Sometimes my MPEG-encoded stream I get from my DTV provider has enough errors to stall and cause artifacts. When NASA wants to use Ogg for a non-repeatable stream from outer space, they should be able to. Again, overhead is a small cost to pay these days.

      If they "maybe intended" it for some hypothetical applications, making it a mandatory feature that is useless in 99% of all practical applications both today and in foreseeable future is kinda useless. In any case, error detection is much better handled at lower level, on the transmission protocol.

      Ah, well, what is reliable these days? Ever used a large array of hard drives? Ever used a freakin' dial-up connection? As the makers of ZFS, Google and a few others recently have shown hard drive and memory reliability is not as good as we take for granted. Silent data corruption is a major cause of data loss these days.

      You need to start with a solid reference for your final claim. Even if provided, though, this doesn't change the fact that a container format for streaming data is not the best place to do error checking, since it imposes this burden on all users, regardless of any error checking already present on lower levels (which may, and, in fact, almost always is enough for the practical application at hand).

      Whoop-dee-doo, you made it half the size bu

  11. A better free container, IMO: Matroska. by Hurricane78 · · Score: 3, Interesting

    Besides it being EBML (a binary and efficient kind of XML), I’ve yet to see a feature that it can’t do. Even a complete 3D TV series with multiple perspectives, languages, subtitles, additional content, hull cover... streamed over the net in one file? No problem.

    Also, it’s already the format of choice for HD video and multichannel audio format rips on the net.

    A competitor would be nice. Unfortunately, OGG can’t hold a candle to it. But if they manage to catch up, they will be very welcome.

    --
    Any sufficiently advanced intelligence is indistinguishable from stupidity.
  12. Overly-large analysis of article by azmodean+1 · · Score: 4, Insightful

    Quite a bit of the analysis seems to be reasonable on the surface, but something about the way it was presented set me off in a geek-rant that I put in the comments. Since I'm having trouble posting that comment on the site, here it is.

    Many of the points sound reasonable, but the argument is strongly undermined by the fact that it offers not a single apples-to-apples comparison between ogg and any other container format in the article. On a section-by-section basis:

    Generalities/codec mapping:

    Article complains about how there is no global mapping, but does not assert that other containers have one.

    Overhead:

    The breakdown of where space is wasted is informative and mostly reasonable, but some of them seem to be a reach, such as the checksum being unneeded, and the suggestion of implementing the functionality in optional fields seems like a bad idea to me in general, since it will make the header variable-length, which is something to strongly avoid in my experience. Finally, when the article does "compare" ogg to mp4, it compares some rather hand-wavey numbers for ogg to a different scenario for mp4.

    Latency:

    The article fires off a bunch of numbers here, but then offers no comparison to the alternatives. In fact it don't even provide an explanation of how other formats avoid this latency in theory, much less in practice, and instead of showing how bad the latency is, it uses it as a platform to show that a naive reaction to the issue will cause bad header overhead.

    Random Access:

    In this section it lists quite a few worst-case numbers for disk accesses (why isn't it being pre-cached by the filesystem?) and then ends with no comparison to alternatives at all.

    Complexity:

    Once again it has a bunch of statements of problems the author has with the format, but no comparisons to "good" formats, in addition this section is particularly weak, with statements like, "implementation is annoying", and "ambiguity is bad".

    Final Words:

    "We have shown" is a rather specific claim to make, which the article has not remotely achieved. This pretty much sums up the whole article, which is titled "Ogg objections", but then tries in the text to bill itself as a rigorous analysis of ogg, which it is not.

    If the author had matched the tone of the article to the title, this would be reasonable, but he only hurts his position when he throws around phrases like, "True generality is evidently not to be found with the Ogg format.", "The Ogg format is clearly not a good choice for a low-latency application.", and "We have shown the Ogg format to be a dubious choice in just about every situation.". He has demonstrated NONE of the above claims, and by making them the article has rendered me skeptical of the rest of its claims.

    1. Re:Overly-large analysis of article by pslam · · Score: 5, Interesting

      I'll do some analysis for you:

      Generalities/codec mapping

      The complaint is that there's no up-front header declaring all the streams contained. This is actually absurd - in theory you need to scan the entire file in case someone's just concatenated a video file with an audio file. This was, also absurdly, one of the aims of the Ogg container spec: concatenation. It's awesome to ask implementations to do this.

      Overhead

      One of Ogg's aims was to try to be less than 1% of the total stream space. It does achieve that, but the 'lacing values' end up looking pretty stupid for anything with large packets. It's like the article says: you end up with long strings of '255' summing up to 32-64KB packets, and hey just for extra complexity's sake, you'll have to split them across multiple not-quite-64KB pages. And then figure out where in that mess you're supposed to stick a timestamp: and here's a hint, you first page in that sequence has timestamp 0xffffffff which is nice if you randomly seeked to that place to find a position. God, what a mess that is to implement.

      Then there's decode CPU overhead: the above basically means you end up copying the bitstream, which is a significant few percent overhead when you're talking about video.

      Latency

      You didn't understand his point. The latency is inherent in Ogg due to the large pages (not packets) required to reduce its size overhead, and in the position of the CRC (at the front of the page rather than the end). Reducing the page size makes the page headers start taking significant percentages of size if it's a low bit rate stream, e.g internet audio.

      Random Access

      Try pre-caching a 2GB video file. Or try pre-caching a 2GB video stream coming off the internet where the other end of the pipe is the other side of the world. Random access in these two realistic cases (if you'll admit that) requires a look up table, and it's precisely why many containers DO.

      Complexity

      The lacing values crossing pages, packets crossing pages, position of CRC, position of timestamp between packets/pages especially when cross-page, timestamps between logical streams (elementary streams), and other oddities/idiocies all ADD UP to make it a bloody mess to deal with. You end up just making copies of packets out of the stream, which is inefficient. In fact, that's exactly what the official Xiph codecs do: they make ugly copies. On real world MP3 players (and I've worked on some) that accounts for about 10% of your battery play time right there. I kid you not.

      What this guy is expressing is what everyone who's worked on the Ogg container format itself has found out: it's just BAD at EVERYTHING. It needs replacing with something that doesn't suck, and there are free/open alternatives around. Maybe Vorbis 2 should switch container.

  13. Ah, and now slashdot... by xiphmont · · Score: 5, Insightful

    This whole thing is really about bad blood between Xiph and the mplayer folks. Once, long ago, I made disparaging remarks about a particular mplayer developer's extensive collection of ass hats, and they declared war. This stopped being about facts or reason years ago. Here's the last blog thread that got completely hijacked by the anti-Ogg container wingnuts. It's a hell of a read:

    http://blog.gingertech.net/2010/02/20/googles-challenges-of-freeing-vp8/

    So, rehashing this yet again: The Anti-Ogg bullet points [Not going to bother with complete sentences, because I've wasted too much typing on this recently]:

    1) A few of the mplayer/x264 hackers are right pissed that Ogg and Theora are getting all this attention when x264 is so obviously superior. That simply cannot stand. Since only America has patents and there are no computers there anyway, nobody should have to worry about them. Stick it to The Man! (How very ironic, Xiph being considered 'The Man' by folks contributing to an h264 encoder).

    2) Xiph should immediately drop Ogg for [insert container here], breaking millions of hardware decoders and hundreds of millions of software decoders:

    a) the [patented] mp4/MOV container is one suggestion they actually make seriously. Never mind adding 'willful infringement' to breaking the entire installed software/hardware base, this choice would totally redeem Xiph in their eyes. The benefit: by their own figures, it would reduce container overhead from .7% to .3%.

    (Except that number is wrong. I found later that DonDiego screwed up his mp4 overhead figures at the link above; I had simply assumed he got his container numbers right. The mp4 file in his example has almost identical container overhead to the Ogg, a shade under 1%. His demultiplexed mpeg audio and video had framing in them, so it made it appear the mp4 container overhead was much smaller when he subtracted their file sizes.)

    b) OK, mp4 is patented and no better, fine, Xiph should have just used Matroska from the beginning. Despite the fact that Ogg and Vorbis predated it by about five years (also mkv's not been able to interleave until just recently, which == no streaming). This is not to say you can't put Theora and Vorbis in Matroska. It's even a good idea! I've come to like MKV. But for streaming, Ogg is still much easier to deal with. Ogg was designed to stream, mkv was not.

    c) OK, so, mp4 and Matroska are right out for streaming, Xiph should use Nut, which is the system they designed. Nut came ten years after Ogg was already widespread. And looks almost exactly like Ogg. Which is not to say there aren't things about it I like that improved on the Ogg approach. Eg, the packet length encoding is better. It has a conditional checksum coverage feature I had never considered, etc. At some point we'll make those changes when that wouldn't mean completely abandoning any chance we have at adoption just to save a fraction of a percent and add... no new features.

    d) but.. but.. even FLV is better! OK, at this point I can't even entertain the arguement.

    3) OK, maybe not adopt another container, but Xiph should immediately improve/change Ogg for, breaking millions of hardware decoders and hundreds of millions of software decoders for a 'better' implementation that won't actually give users any features they don't have now. FOSS need _tools_, not us wasting time overoptimizing something they couldn't care less about.

    3) 64 bit timestamp! OMG, waste! Wait, mov/mp4 uses 64 bit stamps... Also, plenty of things in Ogg use a full byte instead of one bit because the container assumes octet alignment. Alignment makes it much faster/easier to deal with (you don't need a bitpacker to read pages, and you don't have to repack packet data to embed it into the page). Remember, all the completely unacc

    1. Re:Ah, and now slashdot... by pslam · · Score: 2, Interesting

      What the fuck are you talking about? There is absolutely no "latency" harm caused by the CRC, at least not on any hardware actually able to decode the formats much less encode. If performing the CRC on decode is so burdensome, you can stop checking it once you obtain sync and only check it if you obviously lose sync.

      There may be, for example, 64KB pages, containing many packets. None of the packets can be decoded until the entire 64KB page is received and its CRC checked. This may sound small, but for 32-64kbit stream, that's 10 seconds of latency right there. Alternatively, you can have 1 page per packet, but on 32-64kbit streams you end up with about 5-10% overhead from the container. It is a REAL problem.

      So 5 times the decoding complexity, correctly masking out the right bit, just to save 7 bits out of a half million. Yea, I'll get right on it.

      There is a version field on every page header, and it's 32 bits. It's a tiny waste, but it's still a waste. It's not so tiny a waste on the above mentioned low-latency, low-bitrate streams.

      Ugh! so the amount of data that you must read in order to obtain a framing lock is then infinite?

      Yes. Why not? Packets aren't infinite unless you're deliberately malforming a stream. Codecs generally have 'profiles' defining what the limits are. For example, Vorbis has a soft-limit of 8KB. Framing lock serves a purpose in some transports, but for on-disk, on-disc or WAN transport, it's not a big issue.

      Or if at least the container had simplified framing that could be placed throughout large packets. There are huge advantages to packet streaming being as simple as possible. Copying the packets out of a video stream is a bad thing for CPU and power consumption.

      Did you even bother to spend five minutes thinking before posting this crap? The designers of Ogg obviously spent a lot more time.

      I've spent a very long time with the Ogg container format, as well as most of the others in common use. That's why I can recognize the problems with it, as can the ffmpeg developers, as can all the other developers I've worked with at various companies. It's universally hated by anyone who's had to deal with integrating it into a project already supporting other containers/codecs.

      If you're reading this, Monty - it's not just bad blood with ffmpeg. I can't think of anyone I've worked on Ogg with who would admit to liking it, and who hasn't had to spend hours re-working their nice A/V streaming designs to work around its oddities.

  14. Ogg needs to die so Vorbis and Theora can live. by pslam · · Score: 5, Insightful

    I sadly have to agree, and I've voiced the same objections for a long time. It really is like he tells it: it's just bad at everything it was intended to achieve. It's a source of bugs, it's horrendously complicated to support, and it's horrendously inefficient at anything but audio (and even then, not so good).

    It seems to me, most of what went wrong was trying to support concatenation of Ogg streams. This is a nice idea, but actually quite a rare case. It's also incredibly naive for the specification document to request that Ogg implementation detect this. What, I'm supposed to scan the entire file in case that happens? No. I'll just not be compliant to that, thank you very much.

    I even wrote my own Ogg/Vorbis decoder from scratch a while back (and dabble every now and then), and found Ogg to be a never-cooling, never-extinguishing steaming pile of hippo crap left over from consuming a dog. It just made everything so difficult to do. Seeking a stream involves divide-and-conquer - not necessarily a bad thing, but when you have huge streams the number of seeks can be bad. Not to mention if your stream has an endpoint the other side of the Atlantic Ocean. Why oh why did they pick timestamps being at the END of a page and indicating the output byte count produced by the END of that page? That little detail alone probably cost me days of debug.

    I almost gave up at one point and went to a container format of my own which would have worked much better. Header: 'CONTAINER v1'. Packet: 'MAGIC', 4 byte Length, 4 byte Output pos. Job done. The sad fact is, that's easier than Ogg, smaller than Ogg (unless you're talking really low bit rate), and does entirely the job of Ogg without the complexity.

    I'm probably going to add a Matroska container to my codec just to see how easy they are to produce. The spec looks fantastic, but the devil's always in the details - although seeing the praise on various (engineer) forums, it looks like the way to go.

    So, Ogg, please die. We need you to get out of the way.

  15. NUT open container format by KonoWatakushi · · Score: 2, Interesting

    NUT is another alternative, which is open, simple, and well designed. Along with Matroska, it is also capable of containing Ogg Theora and Vorbis streams, so there is really is no good reason to use the Ogg container anymore. The author of the article is correct--the Ogg container is an awful format.

    The main complaints about Matroska are two-fold. One, the EMBL encoding is overly complicated. It requires a considerable amount of code to parse, and also imposes an unnecessary degree of overhead. The second is a much more serious problem: a Matroska file can only contain one timebase. Thus, in order to mux streams with different timebases, approximation is required. To accurately represent the converted timebases, it is necessary to use a much finer granularity, and then you also lose the exact timestamps.

    The NUT specification and code is available from svn://svn.mplayerhq.hu/nut, and the (de)muxers are included in MPlayer/FFmpeg, VLC, and probably elsewhere.