Let me state for the record that I'm a total noob when it comes to Hi-Fi sound systems, but I am rather picky about the sound quality. Normally I listen to CD recordings ripped to FLAC in 16/44, but I have several albums that are also ripped from vinyls to FLAC in 24/96. But it seems that I can't tell the difference between 16-bit and 24-bit versions (except for some vinyl noises, of course). That can be due to several reasons:
- my equipment (onboard audio, monitor headphones) isn't good enough to make any difference,
- my system is not playing audio in 24-bit 96 kHz,
- I am physically unable to hear the difference.
So here is my question, how do I tell if my system can play 24-bit sound with 96 or 192 kHz resolution? And if it can, how do I tell that it plays it instead of downsampling to 16-bit / 44 kHz?
Also, what hardware (audio cards, amplifiers, etc.) would you recommend to play such recordings on Ubuntu?
To find out what your sound card supports, have a look at
(you can just type
cat /proc/asound/card0/codec#2
in a terminal to read it)Now, the 0 and the #2 may vary for you, type
cat /proc/asound
into the terminal and hit tab to see what's there,in this file (which isn't really a file, but never mind), you'll find something like this:
Also, you may be on the safe side typing
cat /proc/asound/card0/codec#2 | grep rates
and looking at the lowest common denominator, so to speak.But: The DAC (digital to analogue converter), which the sound system really has nothing to do with, may just interpolate the signal, the sound card may even do some false advertising, you have no way of knowing safe from looking at the manufacturers website.
The reason for you not hearing a difference (I assert that there is one to be heard, all though that's subject of great debate) is - probably - that the DAC just isn't good enough. It's by far the weakest link (inside your computer).
As for your second question: While this of course isn't the place to discuss it, have a look at stuff like the "ESI Juli@" or the "Dr. Dac Nano", they are reasonably priced and play 192kHz / 96kHz respectively - and they're widely acknowledged to be "okay" by the ever picky audiophile community. Also, the best sound chip will do no good if the headphones/speakers/amplifier can't keep up.
I know this is an old question, but I stumbled upon it when I was researching similar questions of my own, and in the mean time I found an answer to this particular part of the original question, which hasn't been answered yet:
The short answer
In most cases you can be sure that your system is downsampling your high quality music. By "most cases" I mean regular, everyday, normal operating system set-up.
The long answer, with a guide on how to verify it on your own
First, some assumptions - let's say your primary sound card is
card0
(as in the first answer to this question), and that the standard stereo output (for front speakers) goes to thepcm0p
device on that card (which stands for "PCM device 0, playback"). In such case, the file you are interested in is the following:/proc/asound/card0/pcm0p/sub0/hw_params
where
sub0
is a sub-device (more on this in a moment, but when only one sound is being played-back, thensub0
is the sub-device it will be sent to). If no sound is currently being sent to a particular sub-device, then the contents of the correspondinghw_params
file will just beclosed
. So first you need to start a playback of your favourite, high quality sound file (that you know is more than 16bit and/or more than 44kHz) and then look into thehw_params
file, checking what is theformat
andrate
stated there. For instance if you know that your sound file uses 24 bits per sample, and you seeformat: S16_LE
(16-bit signed integer, little-endian bit ordering), then you know that it is being downsampled somewhere along the way to your sound card.If you see that your file is being downsampled, and would like to check wich part of your system is responsible (sound server? music player?), then read on.
First a bit more on the sub-devices, as promised. If your sound card supports hardware sound mixing, then the playback device will have multiple sub-devices. If it doesn't support hardware mixing, it will have only one sub-device -
sub0
. But even if it does have multiple sub-devices, it is rather certain that onlysub0
is going to be used. That's because most (all?) modern operating systems use software sound mixing. Ubuntu, for instance, currently uses PulseAudio sound server, which does software mixing before it sends the sound further down the operating system. With hardware mixing, sound from multiple sources (multiple music players, for instance), would go to different sub-devices, and then the sound card would do the mixing in hardware. With software mixing, the sound from all sources goes to thesub0
sub-device. Just something to keep in mind - remember to look at thehw_params
file in the correct sub-device.Back to the main topic. Since we are talking about Ubuntu, we will stick to its software stack - at the backend of PulseAudio there is ALSA, which is the interface that talks to the hardware drivers, so that PulseAudio can be a fancy, high-level sound server which doesn't bother knowing what hardware it is talking to.
Knowing all the above, we can start ruling out potential suspects. We can really rule out automatically any sort of music player, as the only thing they do is they just open the sound file, decode it if it is encoded in some format other than PCM, and send the read/decoded content to, for instance, a sound server.
So we are left with the layers between the sound card's hardware driver and the music player - ALSA and PulseAudio. It is somewhat difficult to replace ALSA (for testing purposes) with some other sound sub-system (yet doable), but it is fairly easy to temporarily disable PulseAudio, which will force our music player to talk directly to ALSA. In order to achieve this, we execute the following commands from the terminal (as a normal user):
Now you need to restart your music player, start the playback of your music file, and again look into the
/proc/asound/card0/pcm0p/sub0/hw_params
file. And this time you will see the correct values, which proves that, contrary to some opinions floating around the 'net, PulseAudio does downsample the sound.I did my testing using a high resolution music file (24bit, 96kHz) that I found on a Sony website (https://helpguide.sony.net/high-res/sample1/v1/en/index.html), played it back in VLC and saw in the
hw_params
file that the sound card reports that it is being fed with data in S16_LEformat
, at 48000rate
. Then I've disabled PulseAudio, restarted VLC and played back the same file - this time thehw_params
file reportedformat
to be FLOAT_LE (floating point, which by definition is 32-bit, so actually upscaled from 24bit, probably by ALSA), andrate
to be 96000 (so exactly what it should be).After your testing is done, you can re-enable PulseAudio using the following commands:
Edit: Perhaps I should also mentioned the sound card I used for my testing - (partial) output of
lspci -v
: