diff options
author | Raymaekers Luca <raymaekers.luca@gmail.com> | 2024-04-16 10:09:29 +0200 |
---|---|---|
committer | Raymaekers Luca <raymaekers.luca@gmail.com> | 2024-04-16 10:09:29 +0200 |
commit | 692bc52c20da866630fa401be6740bc38f8f8574 (patch) | |
tree | be52e621dbbb15bfd2f43ec92053e4b0a817c392 /bin/extra/rek | |
parent | 197a1a74f468d9d69d624b19f90280a3946455e5 (diff) | |
parent | 19ea61db733c9152f2b334b0ae9871f81ac3664d (diff) |
Merge branch 'main' of debuc.com:dotfiles
Diffstat (limited to 'bin/extra/rek')
-rwxr-xr-x | bin/extra/rek | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/bin/extra/rek b/bin/extra/rek new file mode 100755 index 0000000..b5baac7 --- /dev/null +++ b/bin/extra/rek @@ -0,0 +1,16 @@ +#!/bin/sh + +# Record desktop with ffmpeg, strip metadata and use mp4 for relative small file size +# copy the path of the output file to the system clipboard for sharing +out="out.mp4" + +# with audio +if [ "$1" = "-a" ] +then + ffmpeg -y -video_size 1920x1080 -framerate 25 -f x11grab -i :0.0+0,0 -f pulse -ac 2 -i default -map 0:v -map 0:a? -map_metadata -1 -map_metadata:s:v -1 -map_metadata:s:a -1 -map_chapters -1 -disposition 0 "$out" +else + ffmpeg -y -video_size 1920x1080 -framerate 25 -f x11grab -i :0.0+0,0 -map 0:v -map 0:a? -map_metadata -1 -map_metadata:s:v -1 -map_metadata:s:a -1 -map_chapters -1 -disposition 0 "$out" +fi + +# copy output path +readlink -f "$out" | clipp |