Audio Compression Primer 236
Hack Jandy writes "For those of you with a little extra time this afternoon, check out Sudhian's primer to all things concerning audio compression. The article details everything from DRM to CRC matrixes (with a healthy dosage of Ogg)."
Re:Virtually dismisses lossy compression (Score:2, Informative)
I don't agree with the dismissal of lossy algorithms either, but I think it makes sense given the context.
Re:Is FLAC worth it? (Score:2, Informative)
You might choose Ogg for your audio then sometime in the future, a new lossy format sweeps the industry. Your Ogg files might not convert well to the new format.
and besides...Disk is Cheap!
being pedantic, but... (Score:3, Informative)
Shouldn't that be 1200 kb/s? 150 KB/s * 8 = 1200 kb/s, right? Or is the 150 KB/s figure I'm using incorrect (I could have sworn that was the 1x CD speed)?
AAC (Score:4, Informative)
I did a little googling and found this (http://www.teamcombooks.com/mp3handbook/13.htm [teamcombooks.com]):
FLAC will live forever (Score:3, Informative)
Another reason it's going to be around and much more prevalent as time goes on is that the compression is so good and the speed/resource usage figures are so attractive. When I rip CD's to FLAC I am limited to 40x by my burner (CPU utilization is around 20-25%). When I rip the same CD to ogg, I top out under 30X because the processor has reached 100% utilization.
Fast. Free. Efficient. Frugal with the CPU. What else do you need?
Re:being pedantic, but... (Score:2, Informative)
The 150KB number is for CD-ROM data storage, the gap between the two data rates is for the extra error detection and correction.
Re:128K should be enough for everyone (Score:3, Informative)
Or consider this; since FM radio has a limited range of frequencies that come across well, songs that are intended to be widely played on FM radio (e.g. Britney Spear's latest "hit" song) are actually engineered to sound best in those frequencies. With the end result that when you hear Britney Spears on the radio, the track sounds just like it does on the CD.
Meanwhile, quality music, lovingly mixed onto CD by people who actually give a damn, sounds like crap on the radio..
In other words; if you can't hear the difference between 128kbps and higher, it might just be that you're listening to mass produced music.
As for musicians preferring 128kbps? Well, sound engineers usually don't sit on stage with zillion Watt speakers right next to their fragile precious ears for a reason..
Me, I have crap taste in music AND I'm tonedeaf, so whatever, 128kbps all the way!
(MPEG artifacts in video drive me nuts, though)
Re:being pedantic, but... (Score:2, Informative)
There's even a little more room, in the subcode channels where one can hide the data for CD+G (karaoke) or CD-TEXT.
more algorithms (Score:5, Informative)
Re:The actual meaning of lossless ?? Any clues? (Score:2, Informative)
That is, the checksums for A and A' should match, etc.
That's how I define mathematically lossless.
Whatever this asshat is on about double blind and testing and all that, has more to do with the ability of his FLAC playing equipment to sound the same as his CD player, which is a whole 'nother ball of wax altogether.
Re:being pedantic, but... (Score:3, Informative)
Shouldn't that be 1200 kb/s? 150 KB/s * 8 = 1200 kb/s, right? Or is the 150 KB/s figure I'm using incorrect (I could have sworn that was the 1x CD speed)?
Data CDs are 150 KB/s at 1x, but you're missing an important difference between data and audio CDs.
CD sectors are 2352 bytes (I'm ignoring subchannels here). Data CDs have 2048 data bytes, plus 304 bytes of error-correction data, so every bit comes off perfectly. Audio CDs have no error correction, so they use all 2352 bytes for audio data (on the assumption that a few bits missed won't hurt). That means that audio data is moved 14.8% faster (in b/s) than 9660 data. 1200*1.148 = 1378.
Another calculation you can use instead: 44100 samples/sec * 2 channels/sample * 16 bits/channel = 1411200 bits/sec, or 1378 K/s.
Re:Virtually dismisses lossy compression (Score:3, Informative)
Did I miss a crucial link or something?
Re:One sad bit.. (Score:1, Informative)
Re:128K should be enough for everyone (Score:4, Informative)
Bose is doesn't make high-quality speakers, they make expensive speakers that don't perform nearly as well as alternatives (for instance, the Acoustimass satellites use crappy paper cones that perform poorly in the upper frequencies). A $300 pair of B&W DM302's will thrash anything Bose makes soundly for sound quality. Also investigate Hale, Thiel, or Paradigm. If you really want to spend thousands, spend it on Magnepan (Magneplanar 1.6Q) or Vandersteen (2ce signature) or the higher end speakers from the companies I already mentioned. But those DM302's are good enough to be highly rated by places like Stereophile magazine and they're an incredible deal.
If you really want a bunch of little satellite speakers, Energy makes a much better sounding (and somewhat cheaper) system like that. I hear from people I trust that Tannoy makes an incredible one as well, but I haven't heard it.
Actually, you hear quantization distortion (Score:2, Informative)
The MDCT in itself is actually lossless. Any distortion you notice is most likely introduced by the quantization applied post MDCT during compression.
ARRRG! He gets Nyquist WRONG! (Score:4, Informative)
WRONG!
Nyquist's criterion is "You must have at least twice as many samples as the largest BANDWIDTH of the signal in order to correctly reconstruct it."
You can take a 10.7 MHz signal, and sample it at 10000 samples per second, and correctly reconstruct it, so long as the signal is guaranteed to be bandwidth limited to 10.7 MHz +/- 2.5 kHz. This is often done in software defined radio to aquire the signal from the intermediate frequency (IF) of the analog front end.
You also have to have an appropriate reconstruction filter at the output of the system in order to correctly recover the signal - if you don't have the right reconstruction filter, you will NOT reconstruct the signal correctly.
You also have to take into account the effects of any signal modulation - take a 20 kHz sine wave, and burst it for 10 msec, and you widen the bandwidth of the signal by about 100 Hz (depending upon the exact shape of the burst - a perfect square burst will widen the signal as a sinc function and will, in effect, increase the bandwidth to infinity, which is why square bursts are generally Considered Harmful in communications work).
Also, you don't oversample a signal in time to account for "rounding errors" - you oversample in time because the frequency response of sampling a system in time introduces a sinc response in frequency - by moving the sampling rate up you reduce the impact of this response on the recovered signal's frequency response. You also greately ease the requirements on the reconstruction filter - the filter can be wider (have fewer poles in the transfer function - thus fewer parts needed).
iPods don't play .ogg (Score:2, Informative)
"VBR" 320kbps (Score:3, Informative)
Sampling frequency would typically be 44.1KHz, bitrate would be 128kbps. Also, FM radio quality (with good reception) compares to about 96kbps well-encoded mp3, so there's not much point in them recording higher except for archival purposes.
You should be using LAME to encode, and LAME only goes up to 320kbps (blade for instance goes up to 384kbps, but is much lower quality), ergo you can only have 320kbps CBR, not VBR.
And to everybody else out there who complains about background noise, you should be extracting digitally from the CD!
flac doesn't seem to have come far enough yet for me (500+ albums is a lot of diskspace if it's around 300MB/album), but to my ears on my equipment (Klipsch £250 (pound sterling if that doesn't come out) speakers, cheapo SB Audigy2 soundcard), lame --preset standard (around 200kbps VBR) sounds damn near perceptual transparency.
Re:more algorithms (Score:3, Informative)
Re:ARRRG! He gets Nyquist WRONG! (Score:3, Informative)