Falsely Configured 24 bit Output(?)

Optimize your system for ultimate performance.

Moderators: MattKingUSA, khz

Post Reply
nyckreima
Posts: 1
Joined: Thu Nov 01, 2018 4:15 pm
Contact:

Falsely Configured 24 bit Output(?)

Post by nyckreima »

Intro/backstory; can skip to next paragraph:
Hello! This is my first post, am totally new, so sorry if it's not on the most appropriate board, irrelevant to this forum in general, etc.
I have recently been enlightened in finding that running a JACK server session for audio outputs that have a sample rate that is higher than 41khz and then stopping said session when decent audio quality isn't required and using PulseAudio is completely unnecessary.
I now utilize the infinitely less tedious and better sounding method of using PulseAudio with a properly configured /pulse/daemon.conf, which automatically switches my DAC between 41khz and 96khz depending on the current output.

Main issue:
I am unsure if my DAC is properly outputting 24 bit audio. This could be due to numerous things, including insufficiently sensitive ears, and I would like your help in pinpointing which thing(s) is(are) causing the issue.
What led me to this suspicion is the output of "pacmd list-sink-inputs" when playing 24 bit music from Clementine (ignore title of actual pastebin, woops): https://pastebin.com/ETzYtR9n
I have set the default sample format to float32le, so I should have 32 bit playback by default, no?
Here's my daemon.conf: https://pastebin.com/aWteXwKM

Appreciate any help of course, thanks
User avatar
bluebell
Established Member
Posts: 1923
Joined: Sat Sep 15, 2012 11:44 am
Location: Saarland, Germany
Has thanked: 112 times
Been thanked: 119 times

Re: Falsely Configured 24 bit Output(?)

Post by bluebell »

Not all interfaces are happy when they have to switch their clock rate.

One way to become a happy pro-audio Linux user:

- Consider if you really need more than 48000. See https://people.xiph.org/~xiphmont/demo/neil-young.html
- Configure jackd to the highest quality you want. Many interfaces work best with 48000 or a multiple of 48000.
- Use jack-sink in Pulseaudio. That means Pulseaudio outputs via jackd and jackd has to be running all the time.

Works perfectly on my machines.

jackd will tell you what driver it uses. e.g.:

Code: Select all

creating alsa driver ... hw:USB|hw:USB|128|3|48000|0|0|nomon|swmeter|-|32bit
configuring for 48000Hz, period = 128 frames (2.7 ms), buffer = 3 periods
ALSA: final selected sample format for capture: 32bit integer little-endian
ALSA: use 3 periods for capture
ALSA: final selected sample format for playback: 32bit integer little-endian
ALSA: use 3 periods for playback

Linux – MOTU UltraLite AVB – Qtractor – http://suedwestlicht.saar.de/

Death
Established Member
Posts: 372
Joined: Sun Oct 11, 2015 1:43 pm
Been thanked: 32 times

Re: Falsely Configured 24 bit Output(?)

Post by Death »

I'm not sure I fully understand your issue, but here's a few things.

Most audio interfaces are 24 bit. When you use 32 bit floating point in your DAW, that's just the DAW processing in that way, internally. The in and out of your audio interface will actually be 24 bit.

Bit depth in audio just determines the amount of dynamic range available. CD's are 16bit and that is great for playback (People utilise only a small amount of the dynamic range available with 16 bit in their music). The time when you really want more is for recording and mixing so that you can have a lower noise floor.

Are you sure your audio interface is 32 bit? Also, the bit depth of the file your're playing is what matters. Any extra bit depth outside of the file is doing nothing to help.

I might be off the mark a bit with your issue, but I hope that info is of some use.
User avatar
AlexTheBassist
Established Member
Posts: 353
Joined: Mon May 19, 2014 3:44 am
Location: Russia, Moscow
Been thanked: 1 time

Re: Falsely Configured 24 bit Output(?)

Post by AlexTheBassist »

Death wrote:Are you sure your audio interface is 32 bit? Also, the bit depth of the file your're playing is what matters. Any extra bit depth outside of the file is doing nothing to help.
There are no 32-bit audio interfaces, they are either 16- or 24-bit. But 24-bit interfaces use “24 in 32” mode for data transfer, as it's a lot more easy to align data chunks (called buffers in most of multimedia appliances) if each sample is 4 bytes long instead of 3, since computers we use are binary, and shift operations are cheaper than real multiplication. That's also why power of 2 buffer sizes (32, 64, 128, 256 etc.) work better than any other.
nyckreima wrote:I have recently been enlightened in finding that running a JACK server session for audio outputs that have a sample rate that is higher than 41khz and then stopping said session when decent audio quality isn't required and using PulseAudio is completely unnecessary.
This is never needed, as you can both switch JACK buffer size on the fly and have PulseAudio as a permanently (or temporary, if you need those extra 2 percents of CPU when mixing) connected JACK client. I won't describe how to do that, bluebell already did it about the latter, and it's too obvious for the first part to even start explaining that.

By the way, where did you get that exotic audio interface that works on 41K sample rate? I've never seen such a rare thing in my entire life.
nyckreima wrote:I now utilize the infinitely less tedious and better sounding method of using PulseAudio with a properly configured /pulse/daemon.conf, which automatically switches my DAC between 41khz and 96khz depending on the current output.
Why would you ever need 96 KHz? It's useless even for most of production cases, as it enables the need for a low pass filter on every track set around 22 KHz (a limit for the most of audio equipment, both for mics and speakers/headphones, as everything above 20 KHz is barely distinguishable even by kids, and certainly not by untrained adults), otherwise you'll get crappier sound than intended because of subharmonics (also called undertones) you'll get from ultra high frequency noise when trying to play such material on hardware. Any music released in 88.2, 96, 176.4, 192 or even 384 KHz sample rate, is lowpassed around upper limit of Audio CD/DVD Audio frequency range (which is 44100 / 2 = 22050 Hz for CD, thus 24000 Hz for DVD). After all, higher sample rate is totally useless in case of playback, as linear PCM coding gives a perfect representation of any wave or combination of them up to Nyquist freqency (google for that if you didn't see two examples of it in the text above), i. e. you don't get a “smoother, more analog” sound wave if you use 96 KHz. You don't even get better quality if you go for 48 KHz instead of 44.1 KHz. Higher samplerates (above 48 KHz) are useful in a number of processing cases (especially compression/limiting), but all the DAW plugins doing such processing either have their own resampler or guess inter-sample values some other way, and in most of them you can even choose how high the internal samplerate is: there's that “Oversampling” switch which basically chooses a frequency multiplier. So, even if you're doing some serious, quality demanding production, there's no real need to capture audio at higher than 48 KHz. This was the case years ago, when CPUs were much weaker and couldn't do a lot of resampling on the fly, but today even my mediocre machine can have a hundred or two (or even three!) of plugins running at the same time, processing audio on 50-60 tracks simultaneously with latency as low as 21 ms. So, if there's no point to use that even in production, there can't be any point in using it in playback situations.

Regarding bit depth. As Death already stated above, consumer audio data is usually 16 bit “deep”, and only a little fraction of that dynamic range (of stunning 96 dB, which is like difference between a soft whisper and a jet plane taking off 20 meters near you) is really used in today's recordings. Google for loudness war to know why. If you have some “audiophile mastered” albums, however, 24 bit output may seem reasonable, but the thing is that you need to listen to music at a very high volume (around 105 dB SPL) to actually feel the difference, if there's any at all—most modern music genres are not that dynamic even if mastered properly, and only a limited number of orchestral classical music pieces really need it.
Being creative does not imply being lazy, stupid, or illiterate.

Working in Harrison Mixbus and Ardour on KDE Neon + KXStudio.
Death
Established Member
Posts: 372
Joined: Sun Oct 11, 2015 1:43 pm
Been thanked: 32 times

Re: Falsely Configured 24 bit Output(?)

Post by Death »

AlexTheBassist wrote: There are no 32-bit audio interfaces, they are either 16- or 24-bit. But 24-bit interfaces use “24 in 32” mode for data transfer, as it's a lot more easy to align data chunks (called buffers in most of multimedia appliances) if each sample is 4 bytes long instead of 3, since computers we use are binary, and shift operations are cheaper than real multiplication. That's also why power of 2 buffer sizes (32, 64, 128, 256 etc.) work better than any other.
Yes, that's what I thought. I'd never heard of an actual 32 bit interface, but it's something that can easily get confused..
Post Reply