-
-
Notifications
You must be signed in to change notification settings - Fork 22k
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
[macOS, Windows] Add support for excluding windows from a screenshot. #88950
Conversation
There are only two (actively supported) ways of capturing the screen AFAIK: the wlroots protocol and the desktop portal. The wlroots protocol (wlr-screencopy-unstable-v11) allows only grabbing the whole output or parts of it and it is supported, as the name implies, only on wlroots compositors (and mir apparently, whatever it is under the hood). The portal instead depends on D-Bus (which we support :D ), XDG portals (which we support :DD ) and PipeWire (which we don't support yet :( ). It apparently supports multiple "sources"2 but I'm not entirely sure how it's supposed to exclude things or if they work "dynamically"... Heh, we'll see. I suppose we'll eventually have to implement both methods in general for screencasting (fallbacks and whatnot) but this specific window excluding logic could maybe be implemented only in the portal backend. Footnotes |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I am not familiar with the technical details, but from a usability point of view this is great.
Updated to incorporate #98411 changes (for both native and legacy picker): Screen.Recording.2024-12-06.at.20.43.52.movTested on both macOS and Windows (on Windows, |
Thanks! |
This Makes the picking unusable on Linux, not working at all, I have tried to fix it, but I couldn't exclude the picking popup from screen capture, the only way is to offset the picker window to the left or right based on mouse screen position or to hide the picking popup. Screencast.from.01-08-2025.05.25.25.AM.webmShould i open a new bug for this ? Screencast.from.01-08-2025.03.04.55.AM.webm |
Please open a new bug. |
Adds flag to exclude window for screenshots taken by
DisplayServer
, allowing it to stay on to of the screen part that is captured.Intended for better color picker and similar overlays (e.g., magnifier, color blindness simulator tool).
TODO:
Check if it's possible to implement on X11 and Wayland as well.Screen.Recording.2024-02-28.at.12.14.34.mov