Artix Linux Forum

Artix Linux => Applications & Software => Topic started by: catbug on 20 May 2024, 14:22:53

Title: webrtc screensharing breaks when pipewire is started after kwin
Post by: catbug on 20 May 2024, 14:22:53
i use kde plasma on wayland, and start pipewire/all other relevant processes via an xdg autostart script

the issue is that starting pipewire this way (as well as via a login script through plasma itself) causes webrtc screensharing to be completely broken, due to kwin starting before pipewire

currently i can kill the kwin_wayland process, run "plasmashell --replace" to get screensharing working again, but this is a unwieldy solution, as it requires i keep the terminal window running "plasmashell --replace" open, and sooner or later, pipewire will completely stop working, forcing me to reboot and do the whole thing again

is there some way of autostarting pipewire that ensures it starts before kwin does?
Title: Re: webrtc screensharing breaks when pipewire is started after kwin
Post by: manoca on 21 May 2024, 18:08:18
I guess you could let your init system start it before X starts up? Depending on what you use (openrc, , s6, runit, systemd) you should be able to add the start of pipewire at boot time and therefore before X comes up. I don't know about the other init systems, but in openrc it would look something like this:
Code: [Select]
rc-update add pipewire boot
(ran with root privileges). Remember that you need an appropriate startscript for openrc (I guess you need similar things for the other init systems, but have no idea) to do so in the first place. (/etc/init.d must contain a pipewire start script). But as I've read here: https://forum.artixlinux.org/index.php/topic,2160.0.html there seem to be problems ahead when starting it via init(or do I read that wrong?)
Title: Re: webrtc screensharing breaks when pipewire is started after kwin
Post by: Shoun2137 on 22 May 2024, 15:04:26
^Not viable to run as a openrc service, look at: https://forum.artixlinux.org/index.php/topic,4984.0.html
I know because I tried too... Can't really help too since I'm not using plasma nor wayland ;/
Title: Re: webrtc screensharing breaks when pipewire is started after kwin
Post by: capezotte on 22 May 2024, 17:12:32
There's at least two other middlemen in webrtc screen sharing (xdg-desktop-portal-kde and xdg-desktop-portal). Maybe restarting them instead would work?
Title: Re: webrtc screensharing breaks when pipewire is started after kwin
Post by: catbug on 23 May 2024, 17:46:02
i also want to report this issue somewhere, but dont know if i should report it to the kde devs or pipewire devs, any ideas?