I learned something interesting the other day thanks to a reader email. While it’s seems counter intuitive, there is such a thing as an “uncompressed” FLAC sound file. I say counter intuitive because FLAC is one of the many codecs for audio that is used to shrink the size of the source file without losing any of the data in the reconstruction or decoding of the compressed file. So if the whole point of using FLAC is to make sound files smaller, then why would you have an option in the compression tool set to output a FLAC file that is exactly the same size as the source. It’s because of the metadata capabilities of FLAC files that are lacking in standard uncompressed .WAV files.
Here’s some background. There are two fundamental types of sound files: uncompressed and compressed. We’re all pretty familiar with the uncompressed varieties. These include raw data files, wave files and audio interchange file format (AIFF) files. A .raw sound file lacks a header, which is a chunk of data that is usually appended to the front of the sound data that provides important information about the data words that follow. WAV and AIFF files both include headers that indicate the sample rate, the word length, the duration of the file and other particulars about the rest of the sound file. Wave files were originally associated with PCs and AIFF (sometimes abbreviated to AIF) files were for MACs.
Within the compressed group, there are also two fundamental types of files: lossy and lossless. The less desirable of the pair is the lossy type. When something is encoded and then decoded using a lossy process, it means that some of the informational from the source file doesn’t survive. Examples of lossy codecs (encode and decode) are the ubiquitous MP3, Dolby Digital and DTS (both found on DVD-Video discs) and AAC (Apples’ iTunes flavor). Lossy codecs have dominated the world of digital music since its inception because of bandwidth and storage restrictions. These days, hard drives are inexpensive and bandwidth is much faster than previously. It’s time for lossless codecs.
There are number of lossless audio codecs. When I ask for examples in my audio recording class, invariably a few students will list PCM, AIF and/or WAV. I mark these wrong because they are not codecs at all. PCM (Pulse Code Modulation) is a method of representing digital audio and the other two are file formats WITHOUT any compression.
The first important lossless codec that I remember learning about was MLP (Meridian Lossless Packing). Back in about 2000, the DVD Forum asked a number of consumer electronics companies to submit technologies that could shrink the bandwidth needed for 5.1 surround sound at 96 kHz/24-bits using PCM to less than about 10 Mbps (the bandwidth of a single speed DVD optical drive) from 13 Mbps (the number of 96/24 5.1 uncompressed PCM)…and they had to be able to do it without losing any information from the source file. In fact, for any technology to be adopted it had to confirm that none of the source data had been lost. This validation step makes the ultimate winner MLP more robust than a standard WAV or AIF file. This was the encoding scheme that was used in the DVD-Audio format. A small audiophile company in the UK called Meridian developed it. They are well known for making very high quality hardware…that is also very expensive. (NOTE: It is interesting that they are the company the Neil Young is working with to bring PONO to market in 2014). MLP was licensed to Dolby Laboratories and is one of the standard codecs in the Blu-ray format.
And there’s FLAC, the FREE LOSSLESS AUDIO CODEC. FLAC is a very widely used open source audio encoding scheme that reduces file sizes and maintains 100% of the original source file. As far as I know however, there is no post decode confirmation of the restoration of the source file like MLP. As a result of this and some other factors, there is some debate whether there is an audible difference between a FLAC file and an uncompressed WAV of the same source file.
I’ll talk more about that tomorrow.