2/1/2024 0 Comments Installing bitperfect![]() Any application that is configured to talk directly to ALSA will however now be able to do so, and gain sole usage of the soundcard. From that moment, the system-wide volume controls stops working, as do the hardware volume control keys, and no normal app (web browser etc.) will be able to play audio. As soon as I want to switch to audiophile-quality playback I click the button which shuts down Pulseaudio. With the above setup, on startup the system will be using Pulseaudio and all apps will share soundcard usage, the system-wide Pulseaudio Volume Control application will work and so will hardware volume keys on the keyboard. In this way, I have a button on the taskbar that can toggle whether Pulseaudio is running or not. One can also alter the icon the button uses, so as to select a ‘speaker’ icon from the library of available icons. With the script in hand, in KDE Plasma it is trivial to add a button to the taskbar panel (using the Quicklaunch widget) that can run any chosen script. I’m not going to insult your intelligence by telling you how to save that in a file and make it executable. # use killall to handle cases where there happens to be more than one instance running *) # pidof returned at least one value so pulseaudio running, hence kill it # obtain the pid of the pulseaudio process and count the number of return valuesĠ) # pidof returned nothing so pulseaudio is not running, hence start it (daemonized) I’ve written a script that will detect whether or not Pulseaudio is running, then execute it or kill it as necessary to toggle its state.to add a call to my script that executes Pulseaudio. I’m running gentoo with the KDE Plasma 5 GUI, so I simply go into the System Settings application and browse to Startup and Shutdown->Autostart then click Add Script. It is trivial to create a bash script that executes the above, then call that script when your GUI starts up. To manually start Pulseaudio, we simply need to run it and tell it to run as a daemon:.This file needs to contain just the following line: To tell Pulseaudio not to spawn automatically, create a file named nf in your home directory at the following path:.Use a script to toggle whether Pulseaudio is running or not.Start Pulseaudio explicitly when the linux GUI starts.Set Pulseaudio to not spawn automatically.So then, how do we get these two audio management solutions to co-exist? Switching between Pulseaudio and bitperfect audioĪt a high level, to configure the system to be able to switch between our two ‘audio modes’, we do this: This means that, because we configured it to talk directly to the card via ALSA, gmusicbrowser will complain that it cannot access the sound device when we try to play music. The only problem is that the linux GUI (KDE Plasma in my case) simply tries to access it as soon as that GUI starts up, consequently giving Pulseaudio exclusive control of the sound card. Instead it runs on demand, when an app tries to access it. ![]() Pulseaudio’s architecture is interesting in that it doesn’t boot up when the OS boots up. all sharing the same soundcard, so what to do? Well, on linux Pulseaudio is the de facto solution for shared soundcard usage, and is installed in pretty much every linux distribution out there. Now then, didn’t I say something about “no mixer” earlier on? That’s going to be a pain in the butt if I want to have my web browser, video player, etc. Obviously this means you need to install a few plugins to get a good range of audio format support, but that’s not the focus of this howto – I’ll leave it as an exercise for the reader. I have chosen gstreamer as the transport, on the basis that it has a vast number of audio format plugins in its library (especially that it supports ALAC and AAC). The guide doesn’t reference the fact that gmusicbrowser supports a few different audio transports, and it is within the chosen transport where you need to make the configuration listed in the guide. This guide tells you how to configure it to talk directly to ALSA so as to ensure bitperfect playback. I chose gmusicbrowser as my iTunes-a-like media library. For the audiophile ALSA will do just fine – we don’t need the flexibility and low latency Jack offers. To connect music players direct to sound cards on linux the choice seems to be between ALSA (long history, well-understood) and Jack (pro-audio production capabilities). Adding additional software to the signal path cannot improve audio quality.This rides roughshod over those 192kHz/32bit high-resolution files you paid good money for from HDAudio or wherever. In order to mix, incoming audio streams all need to be resampled to a common audio format (usually 48kHz/16bit).Bitperfect audio on linux (or any OS, really) means your music player’s transport must connnect directly to the sound hardware without there being a mixer in the way.Why? Two reasons:
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |