Support isolated live window ScreenCast streams
Render selected toplevels through a private portal-only capture protocol, preserve logical snapshot geometry, and renegotiate PipeWire video on window resizing. Bound outstanding snapshots and retry temporary contention; stop on source closure and session locking. Validation: portal unit tests (31), capture budget unit, private-bus portal contracts, and real nested/PipeWire isolation, workspace, resize, close and paused-lock tests pass. Independent review cleared. Monitor restore integration timed out on both this build and the unchanged previous compositor under the current nested host.
This commit is contained in:
1 parent
56a888adb3
commit
baca852ee9
26 files changed
+1307
-139
No files matched your search
@@ -109,6 +109,31 @@ impl DirectBackendState {
|
||||
output.current_scale().fractional_scale(),
|
||||
)
|
||||
}
|
||||
pub(crate) fn capture_window_frame(
|
||||
&mut self,
|
||||
state: &Ferese,
|
||||
window: &smithay::desktop::Window,
|
||||
output: &Output,
|
||||
cursor: Option<smithay::utils::Rectangle<i32, smithay::utils::Logical>>,
|
||||
) -> Result<crate::handlers::screenshot::CaptureBuffer, String> {
|
||||
let device = self
|
||||
.devices
|
||||
.values_mut()
|
||||
.find(|device| {
|
||||
device
|
||||
.outputs
|
||||
.values()
|
||||
.any(|candidate| &candidate.output == output)
|
||||
})
|
||||
.ok_or("Window output is unavailable")?;
|
||||
crate::winit::capture_window_frame(
|
||||
&mut device.renderer,
|
||||
window,
|
||||
window.geometry(),
|
||||
output.current_scale().fractional_scale(),
|
||||
cursor.map(|rect| (state, rect)),
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
#[derive(Clone, Debug)]
|
||||
|
||||
Reference in new issue
Block a user