wl-mirror(1)
π wl-mirror(1) β the mirror client that ate π
okay so first things first: this is the manual page for wl-mirror, living in the General Commands Manual section (section 1, iykyk), and it's genuinely one of those little tools that just works. It's a simple Wayland output mirror client. That's the whole vibe. πͺβ¨
π NAME π
wl-mirror β a simple Wayland output mirror client. no cap, that's literally it, and it's iconic for it.
πΈ SYNOPSIS πΈ
wl-mirror [-h,-V,-v,-c,-i,-f,-s S,-b B,-t T,-r R,-S] <output>
yes bestie, <output> is the positional argument and it's a whole mood. keep reading. π
β¨ OPTIONS β¨
-h,--helpβ show the help message and dip. π«Ά-V,--versionβ show version info and exit. classic.-v,--verboseβ turn on debug logging.--no-verboseβ turn debug logging off again (the toggle of the above, obvi). π¦-c,--show-cursorβ show the cursor on the mirrored surface. this one's enabled by default, so you're already slaying.--no-show-cursorβ hide the cursor on the mirrored surface.-i,--invert-colorsβ invert colors on the mirrored surface. chaos mode, highkey aesthetic. π--no-invert-colorsβ un-invert them, back to normal colors.-f,--freezeβ freeze the current image on the screen. π§--unfreezeβ unfreeze it, the image moves again.--toggle-freezeβ toggle that freezing on/off. one flag, three vibes.-F,--fullscreenβ open as a fullscreen window, or make the current window fullscreen in stream mode. main character energy fr.--no-fullscreenβ open as a regular window (enabled by default), or exit fullscreen in stream mode.--fullscreen-output Oβ set a different output to fullscreen on (the default is the current output). this one implies--fullscreen.--no-fullscreen-outputβ set the target fullscreen output back to the current window output. this one implies--no-fullscreen.-s f,--scaling fitβ scale to fit and, if necessary, add letterboxing. enabled by default π-s c,--scaling coverβ scale to cover and, if necessary, crop the image.-s e,--scaling exactβ use exact multiple scaling and, if necessary, add letterboxing.-s l,--scaling linearβ use linear scaling. enabled by default β¨-s n,--scaling nearestβ use nearest-neighbor scaling.-b B,--backend Bβ use a specific screen capture backend. go read BACKENDS, bestie.-t T,--transform Tβ apply a custom transform (rotation and flipping). see TRANSFORMS.-r R,--region Rβ capture a custom screen regionR. see REGIONS.-S,--streamβ accept a stream of additional options on stdin. see STREAM MODE π¦--title Tβ set a custom titleTfor the mirror window. this title can contain placeholders, so go look at TITLE PLACEHOLDERS.
π₯ BACKENDS π₯
autoβ automatically try backends in order of backend efficiency and use the first one that works (enabled by default). the next backend gets selected automatically when the current backend fails to capture a frame 10 times in a row. persistence, honestly. π
the current fallback order is:
extcopy-dmabuf(if compiled withlibGBM)screencopy-dmabuf(if compiled withlibGBM)export-dmabufextcopy-shmscreencopy-shm
export-dmabufβ use thewlr-export-dmabuf-unstable-v1protocol to capture outputs (requireswlroots). this backend keeps the image data on the GPU and does not need expensive copies to the CPU and back. πscreencopy-dmabufβ use thewlr-screencopy-unstable-v1protocol to capture outputs (requireswlroots). this backend keeps the image data on the GPU and does not need expensive copies to the CPU and back. this backend requireswl-mirrorto be compiled with support for allocating DMA-BUFs usinglibGBM.screencopy-shmβ use thewlr-screencopy-unstable-v1protocol to capture outputs (requireswlroots). this backend passes the image data via shared memory on the CPU, but may have better compatibility with complex GPU driver configurations (e.g., multi GPU).screencopyβ automatically triesscreencopy-dmabuforscreencopy-shmand uses the first one that works. fallback works the same as withauto.extcopy-dmabufβ use theext-image-copy-capture-v1protocol to capture outputs. this backend keeps the image data on the GPU and does not need expensive copies to the CPU and back. this backend requireswl-mirrorto be compiled with support for allocating DMA-BUFs usinglibGBM.extcopy-shmβ use theext-image-copy-capture-v1protocol to capture outputs. this backend passes the image data via shared memory on the CPU, but may have better compatibility with complex GPU driver configurations (e.g., multi GPU).extcopyβ automatically triesextcopy-dmabuforextcopy-shmand uses the first one that works. fallback works the same as withauto. β¨
π¦ TRANSFORMS π¦
okay so transforms are specified as a dash-separated list of flips followed by a rotation amount. flips are applied before rotations, and both flips and rotations are optional. custom transformations are applied after adjusting for the wayland output transform, so that if no custom transformations are applied, the mirrored surface is displayed right-side-up. periodt. π
normalβ no transformation (this is the default transformation).flipX,flipYβ flip the X or Y coordinate of the image, i.e.flipXmeans the mirrored surface has left and right swapped. π0cw,90cw,180cw,270cwβ apply a clockwise rotation.0ccw,90ccw,180ccw,270ccwβ apply a counter-clockwise rotation.
the following transformation options are provided for compatibility with sway-output(5) transforms:
flippedβ same asflipX.0,90,180,270β same as0cw,90cw,180cw,270cw.
π REGIONS π
regions are specified in the format used by the slurp(1) utility:
'x,y widthxheight [output]'
in slurp(1) syntax, this would be specified as follows (the last part with %o is optional):
'%x,%y %wx%h %o'
when processing the region option, the region is translated into output coordinates, so when the output moves, the captured region moves with it. so it's lowkey clingy in the best way. π«Ά when a region is specified, the output positional argument is optional.
π STREAM MODE π
in stream mode, wl-mirror interprets lines on stdin as additional command line options. it's giving raccoon-with-a-keyboard and honestly? slay.
- arguments can be quoted with single or double quotes, but every argument must be fully quoted. no half-quoting, bestie. π
- unquoted arguments are split on whitespace.
- no escape sequences are implemented. none. zero. nope.
option lines on stdin are processed asynchronously, and can override all options and the captured output. stream mode is used by wl-present(1) to add interactive controls to wl-mirror. π
π TITLE PLACEHOLDERS π
the title string supports the following placeholders:
{width},{height}: size of the mirrored area{x},{y}: offsets on the screen{target_width},{target_height},{target_output}: info about the mirrored device
a few perhaps useful examples:
--title 'Wayland Mirror Output {target_output}'
--title '{target_output}:{width}x{height}+{x}+{y}'
--title 'resize set {width} {height} move position {x} {y}'
these are literally so useful, iykyk. β
π AUTHORS π
maintained by Ferdinand Bachmann <ferdinand.bachmann@yrlf.at>. more information on wl-mirror can be found at <https://github.com/Ferdi265/wl-mirror>. go give it a star, it's the least you can do. π«Ά
πΈ SEE ALSO πΈ
wl-present(1) slurp(1) sway-output(5)
that's the whole page bestie!! π this beauty is from the wl-mirror(1) manual, dated 2026-02-10 β go mirror some outputs and be iconic about it. πβ¨π¦
π¦ where this page comes from
- alpine 3.24: wl-mirror-doc 0.18.5-r0 Β· GPL-3.0-or-later
- arch rolling: wl-mirror 0.18.5-1 Β· GPL-3.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms