From 07de796b5d1f4db239bd986f553760b868a908f0 Mon Sep 17 00:00:00 2001 From: sgerwk Date: Wed, 10 Feb 2021 17:36:00 +0100 Subject: avdevice/xcbgrab: Add option for grabbing a window The option allows to select a specific window instead of the whole screen. Reviewed-by: Andriy Gelman Signed-off-by: Andriy Gelman --- doc/indevs.texi | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'doc') diff --git a/doc/indevs.texi b/doc/indevs.texi index 3924d03908..b377924c2f 100644 --- a/doc/indevs.texi +++ b/doc/indevs.texi @@ -1564,8 +1564,21 @@ With @var{follow_mouse}: ffmpeg -f x11grab -follow_mouse centered -show_region 1 -framerate 25 -video_size cif -i :0.0 out.mpg @end example +@item window_id +Grab this window, instead of the whole screen. Default value is 0, which maps to +the whole screen (root window). + +The id of a window can be found using the @command{xwininfo} program, possibly with options -tree and +-root. + +If the window is later enlarged, the new area is not recorded. Video ends when +the window is closed, unmapped (i.e., iconified) or shrunk beyond the video +size (which defaults to the initial window size). + +This option disables options @option{follow_mouse} and @option{select_region}. + @item video_size -Set the video frame size. Default is the full desktop. +Set the video frame size. Default is the full desktop or window. @item grab_x @item grab_y -- cgit v1.2.3