Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

How is screen sharing working for you? #4

Open
99linesofcode opened this issue Feb 20, 2025 · 5 comments
Open

How is screen sharing working for you? #4

99linesofcode opened this issue Feb 20, 2025 · 5 comments

Comments

@99linesofcode
Copy link

Hi,

I've been building my own config which is heavily inspired by yours. I'm developing on and daily driving a hybrid Intel (i7 8750H) / Nvidia (1070 Max-Q) laptop running Hyprland and while things have been working well for more than a year, screen sharing just hasn't.

My setup is nearly identical to yours. Pipewire, Wireplumber, xdg-desktop-portal are up and running smoothly. Selecting a video source under OBS allows me to pick a screen/window and it's being piped in and displaying a preview correctly but that's it.

Screensharing in Vesktop just gives me a black screen. Google Meet in Firefox shows a screen selection pop-up but as soon as I select the screen or a specific window it's gone. It seems Google Meet is trying to set up the stream and I can see it

Frankly I'm out of my depth here. Lots of different components coming together here and I'm not sure how to go about debugging this. Hoping you have some pointers for me if everything is working well on your end. Thanks!

Image
Image
Image

@tiredofit
Copy link
Owner

I'm a heavy user of screen sharing and it has been the biggest problem in daily use, due to the platforms I am required to use sadly.

I'm having best success with using the wlr desktop portal. I moved away from trying to get the hyprland portal to give reproducible successful results about 6 months ago. The downside to it is I have to share my entire screen - which in my use case is problematic for those on the other receiving end. My use case it primarily video calls and screen sharing/guidance with technical issues to my staff. I see alot of squinting on the other end as while I'm not running at a super high resolution 2560x1440 is up there. My problem has some additional complexity as I am running 3 monitors which is 3 times the headache with any sort of screen capture situation. Even capturing still images can be hit or miss with Flameshot. Writing this out almost feels therapeutic and I might have to assess this if this is exactly what I want to be fighting with long term!

Paired with Audio problems (i have 3 soundcards) my video conferencing requirements have been dicey. I'm now using Chromium in Webapp mode to use Zoom instead of the Zoom client (complains that I'm not using Gnome or KDE for sharing). Firefox I once used the FirefoxPWA extension to load Zoom which worked quite well for sharing, but bombed spectacularly with the multiple sound inputs and made it difficult to switch back and forth.

X and i3 was much more reliable. I'll ask a colleague who spends more time at this than I do and see if they have any tips..

@99linesofcode
Copy link
Author

That was quick! I'm glad to hear this GitHub issue is useful to you even if it's just therapeutic 😆

I didn't think to check Chromium and can confirm that even with XDPH I can at least share a browser tab. The screen selection menu pops up twice and is behaving similarly to how it behaved for me in the past. It doesn't work but there's at least a hint of it trying to do something.

The first time I select a screen or window it will attempt to start the share but the second time it pops up that process is interrupted and nothing happens. Now I'm curious how I can view the commands being exchanged between the application, portal and D-Bus.

Hope your colleague has some pointers for us. Let me know if there is anything I can do on my end.

@xavierlauzon
Copy link

There appear to be several issues at play here, so I'll address the upstream concerns first.

Vesktop:
Screensharing has been broken for about a month now. It seems they attempted to implement their own selection menu, but it isn’t functioning correctly. I haven’t investigated further to determine if this is due to my configuration; however, I can confirm that the native Discord client now supports Wayland screensharing. That said, I’ve experienced some issues with it capturing keyboard input, which prevents me from using the rest of my system. YMMV

Chromium:
The screenshare selector appears twice, which is quite annoying. After reviewing related Git issues, it seems this stems from Chromium’s screenshare preview feature that opens two instances (one for preview and one for actual sharing). Unfortunately, there is no way to disable this preview feature, and the Chromium team has stated they do not plan to change this behavior.


In my configuration, I am using strictly XDPH (installed via both nixos-config and home-manager), and it has worked well for me—especially since I appreciate using the region selector, which is why I haven’t explored other alternatives.

I haven’t encountered any screensharing issues with Firefox or Floorp; for instance, I recently tested Google Meet on my system, and it worked flawlessly.

These symptoms sound a lot like an issue with pipewire interacting with Hyprland/Graphics drivers. Could you please provide any relevant error logs?

@99linesofcode
Copy link
Author

99linesofcode commented Feb 21, 2025

Thank you both for getting back to me on this as quickly as you did.

@xavierlauzon your reply has been really valuable to me and I've managed to debug the issue because of it. I've touched quite a few files while trying to make sense of it but I think it's a combination of the following that helped me resolve everything:

  • Setup and start Hyprland with UWSM (so XDG_SESSION_TYPE=wayland and XDG_SESSION_DESKTOP=Hyprland are set correctly among others potentially)
  • Check journal output while interacting with xdg-desktop-portal-hyprland through https://mozilla.github.io/webrtc-landing/gum_test.html. Found out I ran into a known issue related to setting bitdepth 10 Error -32, No more input formats. hyprwm/xdg-desktop-portal-hyprland#102. Removing this fixed screen sharing in Firefox.
  • Swapped to Discord as I was both hit by the Vesktop issue you described and WebCord crashing and throwing stack traces. Everything is working smoothly under Discord ☯

@99linesofcode
Copy link
Author

@tiredofit as mentioned above xdg-desktop-portal-hyprland is working fine for me as well. Hopefully your screen sharing woes will be over.

I noticed you didn't disable the following specifically. Might be relevant:

Image

Found in the wiki here: https://wiki.hyprland.org/Useful-Utilities/Systemd-start/#installation

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants