WAV vs. FLAC

All music posts here please.
Lurcher300b
Posts: 933
Joined: Tue Jun 14, 2016 1:58 pm
Has thanked: 0
Been thanked: 16 times

Re: WAV vs. FLAC

Unread post by Lurcher300b »

I have to add a footnote to my point about comparing the checksum. It may be the case that the WAV headers are slightly modified by the process. For example, starting with a WAV that gives the following data dump

Code: Select all

> 0000060  \0  \0 020  \0 200  \0  \0 252  \0   8 233   q   f   a   c   t
> 0000100 004  \0  \0  \0   )   F   X  \0   d   a   t   a 366 244 021 002
> 0000120 211   a 367  \a   & 367 362  \t 366 370 355 365 204 300 364 340
> 0000140 277 364   2 203 363   & 237 363   u   O 362 373 220 362 300   (
> 0000160 361 353 222 361 254 023 360 203 241 360   w 020 357 224 275 357
Then running via sox to flac and back gives the following changed

Code: Select all

< 0000060  \0  \0 020  \0 200  \0  \0 252  \0   8 233   q   L   I   S   T
< 0000100   4  \0  \0  \0   I   N   F   O   I   C   M   T 021  \0  \0  \0
< 0000120   P   r   o   c   e   s   s   e   d       b   y       S   o   X
< 0000140  \0  \0   I   S   F   T 016  \0  \0  \0   L   a   v   f   5   6
< 0000160   .   2   5   .   1   0   1  \0   d   a   t   a 366 244 021 002
The data ( from 366 244 021 002 ), is then identical, but the changed header will invalidate the use of a checksum to check the data.

So don't use this as a indicator that there is something wrong.
Last edited by Lurcher300b on Tue Nov 07, 2017 5:35 pm, edited 1 time in total.

Lurcher300b
Posts: 933
Joined: Tue Jun 14, 2016 1:58 pm
Has thanked: 0
Been thanked: 16 times

Re: WAV vs. FLAC

Unread post by Lurcher300b »

Stripping of the header, does then show that the audio data is identical

sox in.wav out.flac
sox out.flac out.wav

md5sum in.wav out.wav

ef45379e76109211b015764cc844e010 in.wav
8f60cf33ec3fe9defc307688c45992ab out.wav

sox in.wav in.dat
sox out.wav out.dat

md5sum in.dat out.dat

a2d4dd7d70bd7daaf32d54adf427702b in.dat
a2d4dd7d70bd7daaf32d54adf427702b out.dat

User avatar
Fretless
Posts: 9290
Joined: Wed Nov 12, 2014 12:15 pm
Location: Somewhere in Holland
Has thanked: 1487 times
Been thanked: 2280 times
Netherlands

Re: WAV vs. FLAC

Unread post by Fretless »

This is getting complicated - even for me.

Have to give this checksum thing a go. If just to see if there is any visible data corruption.

I do think that audible differences in digital encoding are present. But it is very subtle and possibly more a matter of personal taste/preference than absolute data integrity. It is an area that keeps me busy, though.

Upstairs:
Vinyl
Pro-Ject 1.2 + Grado Sig Jr + Cambridge Alva Duo
DigiVolumio PC + Kiss DP-500 + Sabaj A20d
NVA: P50sa - Cube2 - SSP - LS6+ Sabaj A10a (x2)
Downstairs:
Vinyl
Logic DM101 + Syrinx LE1 + Grado Sig MCX
DigiDenafrips Ares II + Volumio PC + Cambridge CXC
NVA: P50 - BMU+ Aiyima A07 MAX (x2) + Arcam One
HP: HifiBerry Digi+ PRO + Sabaj A10d
Office:
Allo DigiOne SIG + SMSL M300se + Douk G4 (x2)
Mission 760 + Monolith THX AAA 887
Headphones: German Maestro & AudioQuest

User avatar
savvypaul
Posts: 8635
Joined: Tue Oct 11, 2016 7:14 pm
Location: Durham
Has thanked: 1657 times
Been thanked: 2978 times
Contact:
Great Britain

Re: WAV vs. FLAC

Unread post by savvypaul »

antonio66 wrote: Tue Nov 07, 2017 5:19 pm "But any difference in SQ between the 2 formats for purposes of download?"

You would be hard pressed to tell the difference. I have listened to my brothers cd rips onto his homemade (for music) computer using dbpoweramp and any differences are very subtle.
Not talking about ripping CDs...but downloading directly from (e.g) Qobuz
I am in the hi-fi trade
Status: Manufacturer
Company Name: NVA Hi-Fi
https://nvahifi.co.uk/

User avatar
Ithilstone
Posts: 570
Joined: Mon Jun 01, 2015 10:54 am
Has thanked: 73 times
Been thanked: 61 times
EUROPEAN_UNION

Re: WAV vs. FLAC

Unread post by Ithilstone »

Lurcher300b wrote: Tue Nov 07, 2017 5:34 pm Stripping of the header, does then show that the audio data is identical

sox in.wav out.flac
sox out.flac out.wav

md5sum in.wav out.wav

ef45379e76109211b015764cc844e010 in.wav
8f60cf33ec3fe9defc307688c45992ab out.wav

sox in.wav in.dat
sox out.wav out.dat

md5sum in.dat out.dat

a2d4dd7d70bd7daaf32d54adf427702b in.dat
a2d4dd7d70bd7daaf32d54adf427702b out.dat
And with that simple explanation if any one still hears the difference between properly encoded flac and wave then it is down to phenomenon called confirmation bias...
Nothing to see here...
I am in the hi-fi trade
Status: Manufacturer
Company Name: NVA Hi-Fi
https://nvahifi.co.uk/

pgarrish
Posts: 33
Joined: Wed Oct 11, 2017 7:33 pm
Has thanked: 0
Been thanked: 0

Re: WAV vs. FLAC

Unread post by pgarrish »

Fretless wrote: Tue Nov 07, 2017 5:35 pm This is getting complicated - even for me.

Have to give this checksum thing a go. If just to see if there is any visible data corruption.

I do think that audible differences in digital encoding are present. But it is very subtle and possibly more a matter of personal taste/preference than absolute data integrity. It is an area that keeps me busy, though.
Well you've picked the right word - Corruption. FLAC is simply data compression, its the same as WinZip or any other lossless data compression technique - a way of storing ALL OF THE DATA in less space. You can convert from WAV to FLAC to ALAC and back again for ever and the result will never change - unless you have some corruption taking place. Therefore, since the data represented in all 3 formats is identical, either there is no difference to what you are hearing, some lossy transcoding is taking place, or the decoding process is too much for the machine (Apple ipod shuffles weren't able to play back lossless formats for that reason). You wont get subtle changes to the music either, you'll get drop outs or those horrible digital 'shrieks' due to random data. Mp3 is a different animal (as are any lossy compression formats) as they selectively 'loose' some of the information. With everything having GBs of storage now, there really isn't any reason for mp3 unless you want to stream over mobile data.
Rega Planar / Teac T1 / Chromecast Audio - Teac TD1 DAC - Rotel RC850 - HHS500D or DACT passive - Mullard 5-20 Monos - Tannoy Cheviots + Wharfedale sub

Simon Hickie
Posts: 580
Joined: Mon Feb 27, 2017 1:47 pm
Location: East Staffordshire
Has thanked: 0
Been thanked: 1 time

Re: WAV vs. FLAC

Unread post by Simon Hickie »

Logically they 'should' sound the same as the data is a FLAC file and is lossless. However, my speculation is that the decompression process with a compressed FLAC file, regardless of the capability of the computer in question, is doing 'something' to the sound quality in my experience. Those who report similar findings speak of the kinds of things I hear, namely more air, ambience, etc. from the uncompressed format. To complicate matters there are also uncompressed FLAC files which are similar in size to WAV.

To give an example, I was listening to some medieval music with solo singer and the odd instrument. The intake of breath before the soloist began singing was more striking on the WAV file and indeed jumped out at you. I played this after the FLAC version where the intake of breath did not have quite the same impact. Yes the breath was obviously there on the FLAC file but it seemed more incidental and I can't say I noticed it in the same way.

User avatar
Fretless
Posts: 9290
Joined: Wed Nov 12, 2014 12:15 pm
Location: Somewhere in Holland
Has thanked: 1487 times
Been thanked: 2280 times
Netherlands

Re: WAV vs. FLAC

Unread post by Fretless »

Same here, it's micro-details that seem to be lost in the compression process. inflections, striking of keys, placement of sounds, air and ambiance.

My ears tell me this and these are effects that might not be measurable. The untreated WAV files feel 'right' in comparison to FLAC-processed files.

Upstairs:
Vinyl
Pro-Ject 1.2 + Grado Sig Jr + Cambridge Alva Duo
DigiVolumio PC + Kiss DP-500 + Sabaj A20d
NVA: P50sa - Cube2 - SSP - LS6+ Sabaj A10a (x2)
Downstairs:
Vinyl
Logic DM101 + Syrinx LE1 + Grado Sig MCX
DigiDenafrips Ares II + Volumio PC + Cambridge CXC
NVA: P50 - BMU+ Aiyima A07 MAX (x2) + Arcam One
HP: HifiBerry Digi+ PRO + Sabaj A10d
Office:
Allo DigiOne SIG + SMSL M300se + Douk G4 (x2)
Mission 760 + Monolith THX AAA 887
Headphones: German Maestro & AudioQuest

Simon Hickie
Posts: 580
Joined: Mon Feb 27, 2017 1:47 pm
Location: East Staffordshire
Has thanked: 0
Been thanked: 1 time

Re: WAV vs. FLAC

Unread post by Simon Hickie »

Ah well, it's all consistent with the hifi subjectivist philosophy. It's not something we seem to be able to measure but our ears tell us otherwise. I had a few more FLAC files than I realised, but my FLAC to WAV conversions are now up to the end of the Romantic era. Just the modern era composers and the rock / folk / blues to check out now.

Lurcher300b
Posts: 933
Joined: Tue Jun 14, 2016 1:58 pm
Has thanked: 0
Been thanked: 16 times

Re: WAV vs. FLAC

Unread post by Lurcher300b »

But if I understand, you are reporting a change in files that were WAV, then to FLAC, and back to WAV, so the before and after WAV sound different.

I can believe that if the conversion to PCM when playing FLAC causes extra work on the system somewhere then that might be audible, though I would say I would expect the "distance" from the uncompression process to the DAC would affect how audible this was.

Post Reply