Files
feresaria/protocols/ferese-window-capture-v1.xml
T
Samuel Onoja 533cd74c94 perf(capture): add SceneLens GPU streams and retained scene reuse
Use persistent privacy-filtered capture targets and client-owned GPU buffers with fence completion, backpressure, negotiated frame rates and shared-memory fallback.

Invalidate output views on scene changes while preserving inactive-window callbacks and capture revocation. Include OBS memory-mask negotiation and native pixel, transport and recording regressions.
2026-10-24 19:58:54 +01:00

73 lines
3.8 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<protocol name="ferese_window_capture_v1">
<description summary="private native portal window capture">
Captures only a managed toplevel's surface tree, independently of its
workspace, occlusion, animations and output transform. The compositor
advertises this interface only to its native portal executable. Capture
requires session opt-in and fails while locked. Window IDs are compositor
lifetime IDs and never resolve to replacement windows.
</description>
<interface name="ferese_window_capture_manager_v1" version="2">
<request name="destroy" type="destructor"/>
<request name="capture_window">
<description summary="snapshot a managed window">
The two unsigned words encode a 64-bit window ID (high word first).
A version 1 wlr screencopy frame announces a bounded SHM ARGB8888
snapshot. It fails if the target has closed, capture is unavailable,
or the outstanding snapshot budget is exhausted. Resize after the
buffer announcement does not change this frame's dimensions.
Overlay cursor is zero for hidden and one for embedded.
</description>
<arg name="window_hi" type="uint"/>
<arg name="window_lo" type="uint"/>
<arg name="overlay_cursor" type="uint"/>
<arg name="frame" type="new_id" interface="zwlr_screencopy_frame_v1"/>
</request>
<event name="busy">
<description summary="temporary capture resource contention">
Sent before this frame's failed event if the bounded snapshot pool is
occupied. Retry a later frame; this does not revoke the window source.
</description>
<arg name="frame" type="object" interface="zwlr_screencopy_frame_v1"/>
</event>
<event name="geometry">
<description summary="logical dimensions of the announced snapshot">
Sent before the frame's buffer event. These dimensions describe this
captured frame, even if the window resizes before it is copied.
</description>
<arg name="frame" type="object" interface="zwlr_screencopy_frame_v1"/>
<arg name="width" type="uint"/>
<arg name="height" type="uint"/>
</event>
<request name="create_source" since="2">
<description summary="create a persistent window capture source">
Creates a source for ext-image-copy-capture-v1. Unlike a snapshot,
a session waits for content damage and negotiates reusable buffers.
Invalid, closed or protected windows produce a stopped session.
</description>
<arg name="window_hi" type="uint"/>
<arg name="window_lo" type="uint"/>
<arg name="source" type="new_id" interface="ext_image_capture_source_v1"/>
</request>
<request name="refresh_source" since="2">
<description summary="request an initial image after a consumer resumes">
Invalidates the last delivered image for this source's sessions, so
a resumed PipeWire consumer receives an initial image even when the
source is unchanged. Outstanding buffers keep their ownership and GPU
synchronization; this request never cancels a capture in flight.
Subsequent frames continue to wait for source damage.
</description>
<arg name="source" type="object" interface="ext_image_capture_source_v1"/>
</request>
<event name="source_geometry" since="2">
<description summary="logical dimensions of the capture source">
The current logical window size, sent when the source is created.
Subsequent pixel-size changes are announced by the capture session.
</description>
<arg name="source" type="object" interface="ext_image_capture_source_v1"/>
<arg name="width" type="uint"/>
<arg name="height" type="uint"/>
</event>
</interface>
</protocol>