Skip to main content
Topic solved
This topic has been marked as solved and requires no further attention.
Topic: Pipewire and gaming (Read 2020 times) previous topic - next topic
0 Members and 3 Guests are viewing this topic.

Pipewire and gaming

2 Days ago I started this crazy Artix adventure and I've been having fun since. But still being very new and uneducated on the whole thing that I am trying to do here I'll ask for some guide if possible. (English isn't my  native, so sorry in advance)

I've been following some arch wiki guides on how to set up my sound, with uncommenting configs and creating new ones its been a success with pulseaudio and editing the file in '/etc/pulse/default.pa'  finally made me fix the problem with not having both system sounds and ingame sounds because i could choose to have only one; the one I'd opened first.
 
## the fix to have both sounds 
load-module module-alsa-sink device=dmix
load-module module-alsa-source device=dsnoop
# load-module module-udev-detect
# load-module module-detect   -- Source ( https://wiki.archlinux.org/title/PulseAudio )

However I am a big fan of low latency that pipewire offers and I've noticed if I install pipewire I need to remove pulseaudio due to conflicts and if doing so I lose the config file in ' /etc/pulse/default.pa '  and that's a problem witch I can't get pass by ...

###big question
 Is there any pipewire conf file or something I should be able to create to make the pipewire work same as it does with just pulseaudio?   Thanks


Re: Pipewire and gaming

Reply #2
I totally missed the part where the pipewire conf is being mentioned. Guess I will reinstall right now and see if I can get it working this time.

 

Re: Pipewire and gaming

Reply #3
Still there is nothing about pipewire in my /etc/ directory.

Re: Pipewire and gaming

Reply #4
Still there is nothing about pipewire in my /etc/ directory.
Code: [Select]
$ pacman -Ql pipewire | grep conf
pipewire /usr/include/pipewire-0.3/pipewire/conf.h
pipewire /usr/lib/pkgconfig/
pipewire /usr/lib/pkgconfig/libpipewire-0.3.pc
pipewire /usr/lib/pkgconfig/libspa-0.2.pc
pipewire /usr/share/alsa/alsa.conf.d/
pipewire /usr/share/alsa/alsa.conf.d/50-pipewire.conf
pipewire /usr/share/alsa/alsa.conf.d/99-pipewire-default.conf
pipewire /usr/share/man/man5/pipewire.conf.5.gz
pipewire /usr/share/pipewire/client-rt.conf
pipewire /usr/share/pipewire/client.conf
pipewire /usr/share/pipewire/filter-chain/demonic.conf
pipewire /usr/share/pipewire/filter-chain/sink-dolby-surround.conf
pipewire /usr/share/pipewire/filter-chain/sink-eq6.conf
pipewire /usr/share/pipewire/filter-chain/sink-matrix-spatialiser.conf
pipewire /usr/share/pipewire/filter-chain/source-rnnoise.conf
pipewire /usr/share/pipewire/pipewire-pulse.conf
pipewire /usr/share/pipewire/pipewire.conf
Copy that pipewire.conf to /etc and edit it.

Re: Pipewire and gaming

Reply #5
your will have nothing in etc! PipeWire have no more config in etc! here in forum is another topic on this theme. please find it and read, if you want  know  why. otherwise please follow instruction from @strajder. You can use $HOME/.config/pipewire/ instead /etc too.

edit: i edited our wiki and added info about config files of pipewire in /usr/share

Re: Pipewire and gaming

Reply #6
Thanks for all the help, I reverted back to pulseaudio since I couldn't solve my problem even with bunch of conf edits .
There seems to be some other way around this , witch isn't documented as far as I know of, I've tried following https://gitlab.freedesktop.org/pipewire/pipewire/-/wikis/Migrate-PulseAudio * but it was too complicated to follow.

This  is my current pactl info for sink and source

Default Sink: alsa_output.dmix
Default Source: alsa_input.dsnoop

and this works for me.

Re: Pipewire and gaming

Reply #7
I'm using ALSA only and have no problems with sound (though that's for my use case, which doesn't include gaming). I even have Loopback device set up, which enables me to capture sound from my audio output device (for example, record audio from Youtube videos).

I know Mental Outlaw had a video on pipewire recently, but I generally don't install things that try to solve problems I already solved while adding dependencies.

Re: Pipewire and gaming

Reply #8
i am not happy with PipeWire too,  @laky23,  i tested it, but i find it still some art of unstable...  i switched back to pulseaudio too.

Re: Pipewire and gaming

Reply #9
@strajder Hmm.. yea I might try just having pure ALSA with dmix configured , but not sure will that be as simple as it sounds. I have 2 headphones and for them to work I need to edit the /etc/asound.conf each time I connect either 1 of them :
 
Quote
### 1st headphones
#defaults.pcm.card 2
#defaults.ctl.card 2
### 2nd headphones
defaults.pcm.card 0
defaults.ctl.card 0
Reboot goes after I comment/uncomment and it just seems to work for now.

 @alium I  would be fine if not perfectly happy with pipewire since it works great!  Until I try to use an app like cmus or browse youtube while the game is running I get errors like
'ALSA lib pcm_dmix.c:1035:(snd_pcm_dmix_open) unable to open slave' . Or sometimes it will just use my monitors speakers to produce the game sound but getting both of the sounds through  headphones seems to be a hard task at this moment.

Re: Pipewire and gaming

Reply #10
Reboot goes after I comment/uncomment and it just seems to work for now.
You can change the ~/.asoundrc for per-user configuration. Also, when you change the configuration, newly started programs will pick up the configuration change. If you have programs that can't be easily restarted (your DE), it is enough to just relog.

My example: when I want to record sound from a browser, I have this in ~/.asoundrc:
Code: [Select]
pcm.!default { type plug slave.pcm "hw:Loopback,0,0" }
Then I launch a browser instance, and it will output sound to a loopback device. I can then comment out that line and start VLC to simultaneously listen to music.

Re: Pipewire and gaming

Reply #11
Oh wow , I haven't think about it that way since /etc/asound.conf is system wide , makes perfect sense now. Thanks for staying sane with me :D