Become a fan of Slashdot on Facebook


Forgot your password?
DEAL: For $25 - Add A Second Phone Number To Your Smartphone for life! Use promo code SLASHDOT25. Also, Slashdot's Facebook page has a chat bot now. Message it for stories and more. Check out the new SourceForge HTML5 Internet speed test! ×

Journal Journal: My own Vorbis decoder implementation from scratch

Check it out here (edited for new location)

Basically, I've been putting the finishing touches on my from-scratch implementation of Vorbis. It now fits in 110KB of data, 35KB of code, and has some obvious ways to get even smaller. It's fast - about the same as Tremor, if not faster, and there's still some really easy ways to speed it up. It does one memory allocation total. It's in C++, and quite readable (more than Tremor in my opinion :)

All that's left to do is:

  • Implement seeking
  • Implement a callback interface for file reads/writes
  • Distinguish between EOF and bad streams
  • Remove DCT and window coefficient calculation from startup

Not much, eh?

If it weren't for the obvious licensing issues, I'd love to implement it into the Rio portable players. It would fit in with a tiny wrapper into a Rio Karma, and most likely eat up way less battery life than the Tremor library does (Tremor wasn't designed with very limited fast RAM in mind). I'd have to rewrite it from scratch for the Rio S-series and Nitrus (char == int == 24 bits, lovely).

Maybe I'll just do it one day and all of a sudden everyone finds their players magically start playing vorbis files...

Slashdot Top Deals

Where are the calculations that go with a calculated risk?