/tech/ - Technology

Technology & Computing


New Reply
Name
X
Sage
Subject
Message
Files Max 5 files32MB total
Password
[New Reply]


linux_audio.png
(276.1KB, 1404x913)
What's the simplest way to work with Linux sound? If I install Gentoo or something, presuming I have X and a WM up and running but no sound, what's the simplest way to get desktop-quality audio?
General audio software thread as well I guess, since we need something more than this to discuss. Discuss ways of improving the Linux audio mess.
Replies: >>121
ClipboardImage.png
(87.3KB, 1368x575)
>>91 (OP) 
>>92
>What's the simplest way to work with Linux sound?
In practice? Just stick with ALSA plus JACK for DAWs and other audio work and run anything that requires PulseAudio through apulse. PulseAudio just adds another layer of mess above ALSA, aka more stuff that can break, and I've had more problems with it than ALSA on its own.
Your main alternatives are OSS4 and sndio. I have no idea if anyone uses OSS4 but it sounds cool even with the poor hardware and software support nowadays, while sndio is mostly used by OpenBSD users and Voidfags. There's also whatever the fuck PipeWire is, which is trying to replace PulseAudio, JACK, and some video stuff. I know jack shit about it, but it's by a Red Hat employee so there's a good chance it will be cancer.
>Discuss ways of improving the Linux audio mess
Maybe some OSS4 fags can chime in, but it sounds promising to me.
Replies: >>198
>>91 (OP) 
>If I install Gentoo 
On Gentoo you can just enable the alsa USE flag in your /etc/portage/make.conf and enable the relevant options for ALSA and the HD audio in Linux kernel config (i.e. after you run make menuconfig) The tl;dr for PukeAudio is that you enable the kernel options that the ALSA/PukeAudio gentoo wiki articles tell you to enable and just enable the pulseaudio USE flag globally in your /etc/portage/make.conf 

https://wiki.gentoo.org/wiki/ALSA#Kernel
https://wiki.gentoo.org/wiki/PulseAudio#Kernel
https://wiki.gentoo.org/wiki//etc/portage/make.conf#USE

>>121
this.
If anyone uses mpd + alsa, make sure to resample to 32bit with libsamplerate. Audible difference.
Since this thread exists, I'll repost >>>/v/23570

Save this to ~/.asoundrc
possible language: rust, relevance: 10
pcm.!default {
        type asym

        playback.pcm "plug:Output"
        capture.pcm "plug:Input"
}

pcm.Output {
        type dmix

        ipc_key 1024
        ipc_perm 0666
        slave {
                pcm "hw:FIXME,0"

                rate 48000
                periods 128
                period_time 0
                period_size 2048
                buffer_size 32768
        }
}

pcm.Input {
        type dsnoop

        ipc_key 1025
        ipc_perm 0666
        slave {
                pcm "hw:FIXME,0"

                rate 48000
                periods 128
                period_time 0
                period_size 2048
                buffer_size 32768
        }
}Replace FIXME with your audio device number. You can find out what it is by doing aplay -l if you don't have PulseAudio installed or running.
>>91 (OP) 
Whatever you do, audio is shit on Linux. If you have one of these generic on board sound chips it probaby won't be much of a problem, not matter which route you go. But try using some expensive firewire audio interface and you'll have to fight dropouts and shit.
Most consumer sound cards have mixing functionality already included so you could theoretically use bare alsa. However if you have a soundchip that can't mix you could only ever have one application at a time play audio unless you install something like pulseaudio that brings its own software mixing.
Never had any luck with Jack. It does achieve lower latencies but I never could get it to run without timing issues/jitter/dropouts. I'd rather use windows for that stuff, I can't imagine it being very fun running six gorillion VST plugins through wine.
Schismtracker and Renoise work fine though and of course limitations can sometimes lead to creativity.
Replies: >>408
>>406
>However if you have a soundchip that can't mix
>What is dmix (literally post above)
<https://alsa.opensrc.org/Dmix
>NOTE: For ALSA 1.0.9rc2 and higher you don't need to setup dmix for analogue output. Dmix is enabled by default for soundcards which don't support hardware mixing. You still need to set it up for digital outputs.
You don't know what you are talking about, go back.
boomer_wii_punch.png
(139.2KB, 1561x753)
>>91 (OP) 
>alsa + pulseaudio but run both of them through JACK
>you could use apulse to get rid of pulseaudio but for whatever reason in practice, it doesn't work as cleanly
>for an alsa + JACK only build, slam this into your .asoundrc
[code]
pcm.rawjack {
    type jack
    playback_ports {
        0 system:playback_1
        1 system:playback_2
    }
    capture_ports {
        0 system:capture_1
        1 system:capture_2
    }
}
pcm.jack {
    type plug
    slave { pcm "rawjack" }
    hint {
        description "JACK Audio Connection Kit"
    }
}
pcm.!default {
    type plug
    slave { pcm "rawjack" }
}
[/code]
i don't do any music stuff but it does make recording certain sources much easier with JACK

8 replies | 3 files
Connecting...
Show Post Actions

Actions:

Captcha:

Instructions
- news - rules - faq - source code -