Screencast improvements
I have a multi-monitor setup, and I recently screencasted to the Brazilian GNOME community using PipeWire. It went generally smoothly, but one thing bothered me: old frames kept showing. And because I'm terrible at not working during PTOs, here is a fix for that (and, modulo naming changes, I'm generally very happy with the end result).
The goal of this patchset is to make MetaScreenCastMonitorStreamSrc
not record frames when the view (which is backed by a MetaLogicalMonitor) didn't redraw.
This merge request is organized as follows:
- Make ClutterStageView public
- Fix
ClutterStage:after-paint
emission (we are emitting it N times instead of 1!) - Introduce
ClutterStage:paint-view
(it turned out to be very useful, and I suspect it will allow further fixups/improvements) - Introduce
meta_stage_watch_view()
API and family - Make
MetaScreenCastMonitorStreamSrc
use this new API
I believe the most controversial aspect of this patchset is the API introduced at step 4. I'm not entirely satisfied with MetaStageWatch
, but it's the best naming convention I managed to come up with. Suggestions welcomed!