useful_scripts/screc/screenrecord.sh

13 lines
497 B
Bash
Executable File

#!/bin/bash
inres="1920x1080"
fps="30"
bitrate="6000k"
[ ! -z "${1}" ] && filename="${1}" || read -p 'type in filename >' filename && [ -z "$filename" ] && filename="test"
ffmpeg -threads:0 3 -threads:1 1 \
-f x11grab -probesize 42M -video_size $inres -framerate $fps -thread_queue_size 4096 -i :0.0 \
-f alsa -probesize 80M -channels 2 -sample_rate 48000 -thread_queue_size 16384 -i loopout \
-c:v libx264 -b:v $bitrate \
-c:a aac -af asetpts=N/SR/TB /tmp/$filename.mp4
#-allow_skip_frames true