Add Wayland multi-monitor screen capture functionality (#12900)
* Add Wayland multi-monitor screen capture functionality * fix wayland capture issues by reverting to CapturerPtr, the problem was that calling Display::all in get_capturer_for_display was dropping the pipewire capturer and causing the video to freeze. * If running as AppImage or flatpak, ignore the 'multiple' argument * Comment out warning log with unclear purpose Comment out warning log with unclear purpose --------- Co-authored-by: fufesou <13586388+fufesou@users.noreply.github.com>
This commit is contained in:
parent
a375766ac2
commit
eacb07988d
3 changed files with 112 additions and 64 deletions
|
|
@ -661,7 +661,9 @@ fn on_create_session_response(
|
|||
Variant(Box::new("u3".to_string())),
|
||||
);
|
||||
// https://flatpak.github.io/xdg-desktop-portal/docs/doc-org.freedesktop.portal.ScreenCast.html
|
||||
// args.insert("multiple".into(), Variant(Box::new(true)));
|
||||
if is_server_running() {
|
||||
args.insert("multiple".into(), Variant(Box::new(true)));
|
||||
}
|
||||
args.insert("types".into(), Variant(Box::new(1u32))); //| 2u32)));
|
||||
|
||||
let path = portal.select_sources(ses.clone(), args)?;
|
||||
|
|
@ -725,7 +727,9 @@ fn on_select_devices_response(
|
|||
Variant(Box::new("u3".to_string())),
|
||||
);
|
||||
// https://flatpak.github.io/xdg-desktop-portal/docs/doc-org.freedesktop.portal.ScreenCast.html
|
||||
// args.insert("multiple".into(), Variant(Box::new(true)));
|
||||
if is_server_running() {
|
||||
args.insert("multiple".into(), Variant(Box::new(true)));
|
||||
}
|
||||
args.insert("types".into(), Variant(Box::new(1u32))); //| 2u32)));
|
||||
|
||||
let session = session.clone();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue