PDA

View Full Version : Convert Apple Lossless to WAV




KettyKrueger
Mar 25, 2008, 11:28 AM
Would this kind of conversion keep my files lossless? or is this akin to converting mp3s to wavs??



killmoms
Mar 25, 2008, 11:29 AM
They're lossless. WAV is lossless (when encoded as Linear PCM). No loss. :D

zygo
Mar 25, 2008, 01:24 PM
They're lossless. WAV is lossless (when encoded as Linear PCM). No loss. :D

But wouldn't going from Apple lossless to wav cause similar issues as mp3-wav? Taking a compressed file and 'uncompressing' it causes artifacts.

Bunuel
Mar 25, 2008, 02:44 PM
If you zip a wav file and unzip it you don't loose anything. The same goes with lossless.
Mp3/lossy isn't really compression at all, it's subtraction.

killmoms
Mar 25, 2008, 02:47 PM
But wouldn't going from Apple lossless to wav cause similar issues as mp3-wav? Taking a compressed file and 'uncompressing' it causes artifacts.

What about the word "lossless" don't you understand? :confused:

MP3 is not lossless. It's lossy. The artifacts are within the MP3.

Killyp
Mar 25, 2008, 03:16 PM
But wouldn't going from Apple lossless to wav cause similar issues as mp3-wav? Taking a compressed file and 'uncompressing' it causes artifacts.

Apple Lossless is compressed in the same way a ZIP archive is. There is no loss of data, but the file size is smaller. The only downside to Apple Lossless is that it isn't as easy to process as PCM audio (what usually goes into WAV).

Bear in mind that WAV doesn't mean anything as such, it's just a file 'container' where sound of different codecs is stored.

zygo
Mar 25, 2008, 03:37 PM
I stand corrected [but not entirely convinced].

I've have done some research and all tests seem to indicate both file types produce identical audio (phase reverse tests=silence).

What exactly does lossless remove?

What is added again when converting to wav?

Is there changes in bit rates?

killmoms
Mar 25, 2008, 03:40 PM
What exactly does lossless remove?

What is added again when converting to wav?

Is there changes in bit rates?

It doesn't remove or add anything, just like ZIP doesn't remove or add anything from files. Lossless compression merely uses algorithmic data compression techniques. Lossy compression removes data, that's why it's called "lossy." If you really want to learn how these sorts of things work, I'd suggest picking up a book on it.

There's a change in bit rate in that because the file has been compressed, it now takes less bits over time to represent the same data.

zygo
Mar 25, 2008, 04:01 PM
So do lossless codecs effectively get decoded back to PCM during playback?

killmoms
Mar 25, 2008, 04:03 PM
So do lossless codecs effectively get decoded back to PCM during playback?

Effectively, EVERYTHING gets decoded back to PCM during playback, which is then converted into an analog signal which drives your speakers.

zygo
Mar 25, 2008, 04:15 PM
Effectively, EVERYTHING gets decoded back to PCM during playback, which is then converted into an analog signal which drives your speakers.

So PCM is the best suited to A/D and D/A conversion, but is inefficient at storing data as bits?

Mp3 and other lossy codecs were just messy stop-gaps until we got lossless. Plus, for those who don't care about quality, take up less space.

And presumably in the future we will be recording directly to more efficient lossless codecs [such as Apple lossless]?

killmoms
Mar 25, 2008, 04:26 PM
So PCM is the best suited to A/D and D/A conversion, but is inefficient at storing data as bits?

Mp3 and other lossy codecs were just messy stop-gaps until we got lossless. Plus, for those who don't care about quality, take up less space.

And presumably in the future we will be recording directly to more efficient lossless codecs [such as Apple lossless]?

Not really. Just like video professionals don't record directly to H.264, neither would audio professionals record to lossless. It'd just introduce one more piece of unnecessary complexity to the audio acquisition chain. There the focus isn't on saving space, it's on reducing complexity and thus maximizing quality. They have huge gobs of disk space to work with, so size isn't really a concern.

Killyp
Mar 25, 2008, 04:30 PM
The easiest way to think of it is like this.

If there is a large part of the waveform for your music which contains no information (ie, it is silent), PCM would look like '000000000000000000000000000000' (very very very VERY simplified).

Apple Lossless would store it as '0 x 30', 30 being the number of 0s.

This isn't technically 'correct', but it gives you a vague understanding of how it works.

BMP vs PNG is exactly the same, they both produce exactly the same image, but PNG is much smaller than BMP.

zygo
Mar 25, 2008, 04:46 PM
The easiest way to think of it is like this.

If there is a large part of the waveform for your music which contains no information (ie, it is silent), PCM would look like '000000000000000000000000000000' (very very very VERY simplified).

Apple Lossless would store it as '0 x 30', 30 being the number of 0s.

This isn't technically 'correct', but it gives you a vague understanding of how it works.

BMP vs PNG is exactly the same, they both produce exactly the same image, but PNG is much smaller than BMP.

I understand that principle-thats how far my understanding into it goes. But how often is a piece of music completely silent? My confusion in that sense comes from the fact that an audio waveform is constantly changing-therefor it would be unlikely 2bits in the row have the same value [in PCM state]?

Is this confusion stemming from the "very very very very simplified" way of explaining it? Do the 'compressed' bits of data have to be in a row? Or is that just the easiest way to visualise/understand it?

killmoms
Mar 25, 2008, 04:55 PM
From Wikipedia (http://en.wikipedia.org/wiki/Free_Lossless_Audio_Codec):

FLAC uses linear prediction to convert the audio samples to a series of small, uncorrelated numbers (known as the residual), which are stored efficiently using Golomb-Rice coding. It also uses run-length encoding for blocks of identical samples, such as silent passages. The technical strengths of FLAC compared to other lossless codecs lie in its ability to be streamed and in a fast decode time, which is independent of compression level.

Run-length encoding (a very basic and specific sort of encoding) is what Killyp described above. See the linked bits in the original article for explanations of linear prediction and Golomb-Rice encoding. Hope you like math! ;)

zygo
Mar 25, 2008, 05:14 PM
Run-length encoding (a very basic and specific sort of encoding) is what Killyp described above. See the linked bits in the original article for explanations of linear prediction and Golomb-Rice encoding. Hope you like math! ;)

I hate maths even more now!!!! haha!

And from reading up through those wiki's I'm even more confused as to what it's doing! But thanks for the link. At least now I know not to get into coding or too deep into compression techniques!

Sorry to the O/P for half hijacking your thread!

KettyKrueger
Mar 25, 2008, 05:15 PM
Thanks for the replies!!

The reason I asked is because my music library is in Apple Lossless but to stream it to my PS3 it needs to be .wav (or a lossy format).

Trouble with wavs is that you can't embed artwork or tags.

Oh well, at least I can enjoy my lossless music in the living room :)

killmoms
Mar 25, 2008, 05:17 PM
I hate maths even more now!!!! haha!

And from reading up through those wiki's I'm even more confused as to what it's doing! But thanks for the link. At least now I know not to get into coding or too deep into compression techniques!

Sorry to the O/P for half hijacking your thread!

To quote the great sage Strong Bad:

"Technology is... magic! Basically, it's something that's really cool that you don't know how it works, and when it breaks you have to buy a new one!"