FLAC.js, a FLAC Decoder Written Entirely in JavaScript, Is Here

The web is becoming a powerful platform for audio apps

By on June 16th, 2012 14:51 GMT

HTML5, CSS3, WebGL and a number of other loosely associated technologies promise to transform the web into an app platform as powerful as any operating system. We're not quite there yet, the apps that are available aren't that complex or are not on par with native alternatives, for the most part.

What's more, the heavy lifting is still done by Flash and other proprietary technologies. But things are changing, slowly but surely.

One very interesting development is the Web Audio API, a low-level API that promises to provide a solid base for any app that does serious audio work, from chat apps to audio editors. It's still early days, but there is a lot of promise.

Official.fm Labs, who's goal is quite simple - "make the web a better place for audio," - has been working towards this and has quite a few things to boast about.

One of the latest developments is a FLAC audio decoder written entirely in JavaScript. What this means is that any web app can now add FLAC playback and processing without the need for any local codecs or plugins to be installed.

Having web native decoders bypasses one of the big shortcomings of the now-well- established HTML5 <audio> tag, the fact that it depends entirely on codes either built into the browser or the operating system.

Official.fm Labs has already written an MP3 decode and an Apple Lossless (ALAC) decoder entirely in JavaScript. The source code for both, as well as the FLAC decoder and several other projects the team is working on, is available on GitHub.

Now that the Web Audio API has been chosen by the W3C for standardization, things will move faster. Web Audio API is backed by Google, Mozilla has been working on a similar project, the Audio Data API.

"The HTML5 Audio tag is great, but codec support issues are very real and encoding multiple formats is unacceptable. We know that browsers will never agree to support every codec possible, but with a baseline of the Web Audio API supported, we can support whatever codecs we please via a JavaScript decoder," Official.fm Labs said in its announcement.

"Additionally, JavaScript audio decoding opens up a number of doors for previously impossible web applications, such as DJ apps, Garageband-esque apps, audio editors and more," it added.

Comments