Apple shifts Lossless Audio Codec to open source
Audiophiles pleased at Cupertino’s belated move
Agentless Backup is Not a Myth
Cupertino has open sourced its Apple Lossless Audio Codec (ALAC), seven years after first introducing it.
The ALAC can reduce the amount of storage needed for audio files by as much as 50 per cent, but without losing any of the fidelity of the original recording. This is unlike lossy formats like MP3 and AAC, which strip out sections of the recording - greatly increasing data compression but a cost in audio quality.
“A decoded ALAC stream is bit-for-bit identical to the original uncompressed audio file,” Apple said, announcing the move.
The code has been released in Mac OS Forge under the Apache license version 2.0 and includes the ALAC encoder and decoder as well as alacconvert, which reads and writes audio data between Core Audio Format (CAF) and WAVE files. Unsurprisingly, ALAC is the preferred format of choice for iOS and iTunes.
Apple introduced ALAC in 2004 with the release of the Mac OS X Core Audio framework and it was reverse-engineered a year later by David Hammerton and Cody Brocious. While media players like VLC media player, Boxee, and MPlayer use this to process Apple files, the move will make it easier for audiophiles to use the ALAC format. ®
COMMENTS
re: wow!
It's hardly altruistic; they're trying to do battle with FLAC which is dominant outside of Apple. I'd be more impressed if Apple finally added support for FLAC in iTunes and iPods, which is long overdue.
I remember seeing that page a few days ago and it matched with what I remembered seeing when I was in the market for a new lossless format a few years ago. But I thought I'd do a test with a few of the CDs I have in lossless format.
I picked 5 CDs, mostly randomly, with one from each of five types of music, just to see if some codecs performed better on different types of music. I compressed each of the five CDs by tracks with a bunch of tag info on each track. I used ALAC, FLAC: Level 0, FLAC: Level 5, FLAC: Level 8 and wave formats for each disc.
Genre ........ Artist/Album Name .................................................. Run Time ........ # of Tracks
Classical ... Brahms: Symphony #1 ............................................ 1:07:55 ............ 5
New Age .... Arkenstone: In the Wake of the Wind ....................... 1:00:58 ............ 16
Piano ........ Mozart: Piano Sonata in B-flat Major & C Minor ........ 57:44 ............... 7
Pop ........... Branch: The Spirit Room ........................................ 42:25 ............... 11
Rock ......... KoRn: Issues .......................................................... 53:17 ............... 16
The size was a simple check to see how large Win7 reported the files as. The simpler the type of music, the better it compresses apparently. Overall, the four compression algorithms are close together in size. Sensibly, FLAC level 8 had the best compression and FLAC level 0 had the worst. ALAC was about halfway between the FLAC algorithms. FLAC 5 performed comparably to FLAC 8 with only 1-2MB of difference between them.
Size ........ ALAC .... % ...... FLAC(0) .. % ...... FLAC(5) .. % ..... FLAC(8) .. % ..... WAVE
Classical . 294 MB . 43% ... 303 MB ... 44% ... 289 MB .. 42% .. 288 MB ... 42% .. 685 MB
New Age .. 331 MB . 54% ... 342 MB ... 56% ... 320 MB .. 52% .. 318 MB ... 52% .. 615 MB
Piano ...... 196 MB . 34% ... 198 MB ... 34% ... 182 MB .. 31% .. 180 MB ... 31% .. 582 MB
Pop ......... 311 MB . 72% ... 324 MB ... 76% ... 301 MB .. 70% .. 300 MB ... 70% .. 429 MB
Rock ....... 378 MB . 70% ... 391 MB ... 73% ... 361 MB .. 67% .. 359 MB ... 67% .. 537 MB
Total .......1510 MB . 53% . 1558 MB ... 55% . 1453 MB .. 51% . 1445 MB ... 51% . 2848 MB
The speed test checked to see how fast the entire disc could be decoded. I used dbPowerAmp's "Test Conversion" with no speed limit and highest quality decoding selected. Each set of files was decoded once (I'm lazy and didn't want to sit here 'till morning). Computer is a C2D 2.53GHz with 8GB RAM and a 160GB 5400 RPM 8MB disk drive. This time, ALAC consistantly came out well ahead, though the FLAC versions didn't take too much longer to decode. The FLAC versions seem to require about the same amount of time to decode. On none of the tests did any of the decompressions force the CPU above 90% or above 33% RAM usage. Generally, the decoders stayed around 15-25% CPU usage, though ALAC used 45% to decode the Piano disc. From the looks of it, the bottleneck for both algorithms is the hard drive. Still ALAC decoded faster, which is probably due to the simpler codec
Speed ........ ALAC ...... FLAC (0) ....... FLAC (5) ....... FLAC (8) ....... WAVE
Classical .... 24 s ......... 46 s .............. 33 s .............. 55 s .............. 47 s*
New Age ..... 29 s ......... 37 s .............. 37 s .............. 33 s .............. 48 s*
Piano ......... 17 s ......... 19 s .............. 18 s .............. 22 s .............. 47 s
Pop ............ 24 s ......... 33 s .............. 33 s .............. 33 s .............. 33 s
Rock .......... 32 s .......... 44 s ............. 41 s .............. 40 s .............. 38 s
Total ..........126 s ........ 179 s ........... 162 s ............. 183 s ............ 213 s
* The first two tests for wave decoding completed in a mere 2s and 4s, so they were repeated.
Really, I wouldn't suggest that someone choose between either of these codecs based on the compression size or speed. They're both reasonably close from a practical standpoint. The best reason to choose one over the other is probably which format your devices / OS already have good support for. As other people have pointed out, Apple's iOS devices don't play FLAC media, and ALAC support can be pretty scarse outside of Apple. The one other drawback I can think of, is that many of the existing non-Apple decoders for ALAC don't support high-resolution audio yet. So, if you have DVD-audio discs or HDCDs, you're probably better off with FLAC for now. If you really need to save drive space for your entire collection, you're better off looking at the ape or tak formats instead. Both of those produce smaller file sizes, though they're not as popular right now.
It's almost identical to the already open source and very widely used FLAC codec.

IT infrastructure monitoring strategies
Requirements Checklist for Choosing a Cloud Backup and Recovery Service Provider
Cloud based data management
Enabling efficient data center monitoring
Agentless Backup is Not a Myth