wf-recorder
Record Wayland compositor output
TLDR
Record storing to an MP4 file
Record including audio, both with mic and system sounds
Select and record a portion of the screen using slurp, outputting to default recording.mp4
SYNOPSIS
wf-recorder [options] [output_file]
PARAMETERS
-h, --help
Show help message and exit.
-v, --version
Show version information and exit.
-c
Specify the video codec to use (e.g., h264, vp8, vp9). Defaults to auto-detection.
-f
Specify the output file format (e.g., mp4, webm, mkv). Defaults to auto-detection.
-x
X coordinate of the top-left corner of the region to record.
-y
Y coordinate of the top-left corner of the region to record.
-w
Width of the region to record.
-h
Height of the region to record.
-g
Specify the geometry of the region to record as WxH+X+Y (e.g., 1280x720+0+0).
-s
Frames per second to record
-l
Recording length in seconds.
-d
The Wayland display to record, defaults to $WAYLAND_DISPLAY.
-a, --audio
Record audio (requires appropriate audio sink configured).
[output_file]
Path to the output file. If not specified, defaults to wf-recorder-$(date +%Y%m%d%H%M%S).mp4
DESCRIPTION
wf-recorder is a command-line utility designed for recording the screen in Wayland compositors. Unlike traditional screen recording tools that rely on X11, wf-recorder directly interfaces with the Wayland protocol, offering a more efficient and reliable recording experience in Wayland environments. It captures the output of a specified window or the entire screen as video. It is designed to be simple, efficient, and configurable. You can customize options such as codec, frame rate, and output format.
The core philosophy is minimalism; providing only essential screen recording functionality without unnecessary bloat. It is particularly useful for Wayland users seeking a lightweight and reliable tool for creating screencasts, capturing gameplay, or recording presentations. It supports various video codecs like H.264, VP8, VP9, and AV1, as long as the required encoders are available on the system.
CAVEATS
Requires a Wayland compositor. The availability of codecs and formats depends on the installed system libraries. Audio recording needs proper audio sink configuration.
EXAMPLES
Record the entire screen:
wf-recorder
Record a specific region: wf-recorder -g 800x600+100+100 output.mp4
Record with a specific codec and framerate:
wf-recorder -c vp9 -s 30 output.webm
Record with audio:
wf-recorder -a output.mp4
HISTORY
wf-recorder was specifically designed to address the limitations of screen recording on Wayland. Traditional X11-based screen recorders don't work natively on Wayland. wf-recorder was developed to provide a minimal and efficient solution tailored for Wayland compositors. It has seen active development to improve codec support, stability, and performance.