Frontend for gpu-screen-recorder's replay feature running in the background. More native-feeling alternative for gpu-screen-recorder-ui. Makes use of Global Shortcuts and KDE OSDs.
Note
This app is currently only supported on KDE Plasma (may work on other desktops but it's not guaranteed) and has been tested only on Wayland. I will not provide support or bug fixes for X11 or other desktops, but pull requests with fixes are welcome.
- Native integration with KDE Plasma
- Tray-based controls
- Global keyboard shortcuts for saving and toggling replay recording
- Customizable output directory and file naming
- Automatic clip naming based on the active app, window title, or Steam game
- Flexible audio track configuration
- HDR recording
TrayPlay is available on the AUR as a normal and binary package.
If you're using yay you can install TrayPlay using the following command:
yay -S trayplay-bin
Since version 2.0 experimental Flatpak support has been added. Currently, it's not available on Flathub
as I want to iron it out before publishing it there. You can download a .flatpak file from the Releases tab.
You can install it by opening it in your distro's software center or via CLI:
flatpak --user install <file_name>.flatpakWarning
Flatpak installed that way doesn't update automatically. You have to download the new .flatpak manually.
Install rust toolchain, gpu-screen-recorder and other dependencies. For example on Arch Linux:
sudo pacman -S --needed base-devel rust cargo qt6-tools kirigami gettext gpu-screen-recorder xdg-desktop-portal-kdeClone and build TrayPlay:
git clone https://github.com/kabuspl/trayplay.git
cd trayplay
cargo build --releaseExecutable will be located at target/release/trayplay. dist/kwin_script.js needs to be placed in dist directory relative to current working directory when starting trayplay or at /usr/share/trayplay/kwin_script.js.
To install it system-wide you can execute:
sudo install -Dm755 target/release/trayplay /usr/local/bin/trayplay
sudo install -Dm644 dist/kwin_script.js /usr/share/trayplay/kwin_script.js
sudo install -Dm644 dist/ovh.kabus.TrayPlay.desktop /usr/local/share/applications/ovh.kabus.TrayPlay.desktop
sudo install -Dm644 dist/ovh.kabus.TrayPlay.svg /usr/local/share/icons/hicolor/scalable/apps/ovh.kabus.TrayPlay.svg
sudo find locale -type f -exec install -Dm644 "{}" "/usr/local/share/{}" \;You can configure TrayPlay through its settings menu or directly with a config file which gets saved after the first start at /home/username/.config/trayplay.toml (or other directory set in $XDG_CONFIG_HOME)
# start recording immediately
recording_enabled = true
# directly passed to gpu-screen-recorder as -w option
screen = "screen"
# mkv, mp4, flv or webm
container = "mkv"
# h264, hevc, av1, vp8, vp9, hevc_hdr, av1_hdr, hevc_10bit or av1_10bit
codec = "h264"
# directly passed to gpu-screen-recorder as multiple -a options
audio_tracks = ["default_output", "default_input"]
# framerate of the video
framerate = 60
# clear replay buffer in memory when saving replay so that the next replay doesn't "overlap" with the previous one
clear_buffer_on_save = true
# medium, high, very_high or ultra
quality = "ultra"
# directory where replays will be saved
replay_directory = "/home/username/Videos"
# max duration of a single replay
replay_duration_secs = 180
# replay file naming pattern - available variables:
# %app% - title of the current full-screen window or unknown
# %year% - current year
# %month% - current month
# %day% - current day
# %hour% - current hour
# %minute% - current minute
# %second% - current second
# file extension is added automatically based on video container
file_name_pattern = "%app%/%app%_replay_%year%-%month%-%day%_%hour%-%minute%-%second%"
# only fullscreen windows affect naming video files
detect_only_fullscreen_apps = true
# use steam app name for video naming instead of just window title for steam games
use_steam_game_names = trueFeel free to open issues or pull requests.
Translations use GNU gettext.
Quick start guide:
- Install gettext (
xgettext,msgmerge, andmsgfmt). - Create a directory for your language, for example
po/de/. - Copy the template:
cp po/trayplay.pot po/de/trayplay.po
- Edit
po/de/trayplay.poin a gettext editor such as Lokalize or Poedit. Update its header, includingLanguageandPlural-Forms. - Validate the translation:
mkdir -p locale/de/LC_MESSAGES msgfmt --check po/de/trayplay.po -o locale/de/LC_MESSAGES/trayplay.mo
Only include .po files in the pull request, .mo files are generated during compilation.
