Screensharing under Wayland

Posted on

Problem :

I am using Wayland with Fedora 25.

Pretty much no screensharing tool works correctly. From Chrome, I can share a Chrome window, but nothing else.

I also have to use and when I share a window from that the other side just gets a blank screen.

Is there something that needs to be configured for this to work?

Solution :

Although this is an old question, I’ve found a solution by using the PipeWire technology with Gnome DE (in my case 3.32) and Chrome (at present version 77).

Check this out:

Just open chrome://flags/#enable-webrtc-pipewire-capturer set it as enabled and restart chrome. You’ll be able to share your entire screen or any single window.

I hope it helps

EDIT July 2020:

As of 20 July 2020, since Chrome(ium) is currently using pipewire 0.2 whereas Arch Linux ships pipewire 0.3, you also need to install libpipewire02 for screen sharing to work.

EDIT June 2021:

Concerning debian: The required package libpipewire-0.3-0 is available from debian bullseye onwards.

The ability to do traditional full screen sharing under Wayland is a missing feature, not a bug.

Realistically our only option is to switch back to Xorg. Ubuntu is actually doing this:

There are projects coming (e.g. Pipewire) but it seems like a good year or so before they land in Firefox or Slack.

Screen sharing in Wayland is known to be broken. You say that sharing works
perfectly well in an X11 session, but you prefer to use Wayland.

I am not a Wayland developer (nor a user) and cannot fix the bug.

I have seen comments saying that the problem is mostly with full-screen sharing,
so I suggest that you try sharing only individual windows until the bug is fixed.

Otherwise, your only option is to badger the Wayland developers to fix the bug,
while still using X11 whenever you need to do screen sharing.

Pipewire changed everything. Screen sharing through Wayland is working well on Fedora 32 Workstation, out of the box. At least on Firefox. I haven’t tested other browsers yet.

First, Firefox will request your permission to share your screen, then GNOME will ask whether you want to share one window or the full screen, and which monitor. That’s it. Firefox will pop up a tiny window with a few quick controls for screen sharing.

While you’re sharing the screen, an orange icon will be visible at the top-right corner of the screen, among other system icons. Through that menu you can quickly turn off screen sharing too.

UPDATE 2021-08-26:

Screen sharing through Pipewire on Wayland is working out of the box on both Ubuntu 21.04+ and recent Fedora releases, at least on Firefox.

Leave a Reply

Your email address will not be published. Required fields are marked *