screen-record: added hotkeys and scripts

master
tiyn 2 years ago
parent 6e5fcdec64
commit 0d221f7db0

@ -4,8 +4,16 @@ super + b
$BROWSER $BROWSER
super + f super + f
$TERMINAL -e $FILE $TERMINAL -e $FILE
super + i
record_stop
super + m super + m
thunderbird thunderbird
super + o
record_replay_start
super + p
record_replay_save
super + u
record_start
super + x super + x
pkill -usr1 -x sxhkd; notify-send 'sxhkd' 'Reloaded config' pkill -usr1 -x sxhkd; notify-send 'sxhkd' 'Reloaded config'
super + shift + r super + shift + r

@ -3,7 +3,7 @@
# Requires maim. It lets you choose the kind of screenshot to take, # Requires maim. It lets you choose the kind of screenshot to take,
# including copying the image or even highlighting an area to copy. # including copying the image or even highlighting an area to copy.
output="$HOME/downloads/screenshot-$(date '+%y%m%d-%H%M-%S').png" output="$HOME/downloads/screenshot-$(date '+%Y-%m-%d_%H-%M-%S').png"
xclip_cmd="xclip -sel clip -t image/png" xclip_cmd="xclip -sel clip -t image/png"
case "$(printf "a selected area\\ncurrent window\\nfull screen\\na selected area (clipboard)\\ncurrent window (clipboard)\\nfull screen (clipboard)\\ncolor picker (clipboard)" | dmenu -l 6 -i -p "Screenshot which area?")" in case "$(printf "a selected area\\ncurrent window\\nfull screen\\na selected area (clipboard)\\ncurrent window (clipboard)\\nfull screen (clipboard)\\ncolor picker (clipboard)" | dmenu -l 6 -i -p "Screenshot which area?")" in

@ -0,0 +1,4 @@
#!/bin/sh
killall -SIGUSR1 gpu-screen-recorder
notify-send 'Screen record' 'Replay saved'

@ -0,0 +1,11 @@
#!/bin/sh
window=$(xdotool getwindowfocus)
fps=30
audio="$(pactl get-default-sink).monitor"
format="mp4"
lenght=20
output="$HOME/downloads"
gpu-screen-recorder -w $window -f $fps -a $audio -c $format -r $lenght -o $output
notify-send 'Screen record' 'Replay started'

@ -0,0 +1,10 @@
#!/bin/sh
window=$(xdotool getwindowfocus)
fps=30
audio="$(pactl get-default-sink).monitor"
format="mp4"
output="$HOME/downloads/recording-$(date '+%Y-%m-%d_%H-%M-%S').$format"
gpu-screen-recorder -w $window -c "mp4" -f $fps -a $audio -o $output
notify-send 'Screen record' 'Recording started'

@ -0,0 +1,4 @@
#!/bin/sh
killall -SIGINT gpu-screen-recorder
notify-send 'Screen record' 'Recording stopped'
Loading…
Cancel
Save