Skip to main content
Topic solved
This topic has been marked as solved and requires no further attention.
Topic: is it possible to capture screen with on sway with obs on artix? (Read 1666 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

is it possible to capture screen with on sway with obs on artix?

screen capture missing when i run obs on sway

there is way to capture screen with obs on arch linux

with https://github.com/emersion/xdg-desktop-portal-wlr

exec dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=sway

but is it possible with artix linux runit?

flatpak obs works with gnome wayland, but not in sway.

Re: is it possible to capture screen with on sway with obs on artix?

Reply #1
Doesn't OBS use a gstreamer based plugin to support screen capture on Wayland?

Do you use pipewire instead of pulseaudio? It was partly designed with native Wayland screen capture in mind, although I don't use it so I can't comment on how it's done.

Re: is it possible to capture screen with on sway with obs on artix?

Reply #2
Yes I use pipewire, I tried obs with sway in arch linux and it works with xdg-desktop-portal-wlr. I think I just need a way to active that same environment without systemd.

that is how I found the answer, it is the last post https://bbs.archlinux.org/viewtopic.php?id=267576

I don't know about  gstreamer, I guess I should look into in after school.

Re: is it possible to capture screen with on sway with obs on artix?

Reply #3
According to this article, all you need to do is add pipewire as an input source. If it isn't displayed as an option, you need to explicitly tell QT programs to use wayland explicitly by setting.

Code: [Select]
QT_QPA_PLATFORM=wayland

Somewhere in your shell's profile (.bashrc, .zshrc) or in sway's autostart commands.

 

Re: is it possible to capture screen with on sway with obs on artix?

Reply #4
thanks for reply, I already tried that, does not work.

Edit: I got it working now

 https://github.com/emersion/xdg-desktop-portal-wlr/wiki/%22It-doesn't-work%22-Troubleshooting-Checklist.

There might be a need to add this line on the last line of the config of river and the beginning of the line of the config on sway:
added this to config file and sway takes a long time to start and terminal crashes if i run it without removing I3SOCK from it.
Code: [Select]
exec dbus-update-activation-environment DISPLAY I3SOCK SWAYSOCK WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=sway

anyway i got screensharing working and I don't need keep that in config file.

I added this to
Code: [Select]
/usr/share/wayland-sessions/sway.desktop
Code: [Select]
[Desktop Entry]
Name=Sway
Comment=An i3-compatible Wayland compositor
Exec=env XDG_CURRENT_DESKTOP=sway dbus-run-session sway
Type=Application