Skip to content

Instantly share code, notes, and snippets.

@jorgeramirez
Created January 9, 2015 12:39
Show Gist options
  • Save jorgeramirez/acfb6facc1c12bbcc0bb to your computer and use it in GitHub Desktop.
Save jorgeramirez/acfb6facc1c12bbcc0bb to your computer and use it in GitHub Desktop.
#!/bin/bash
# screencast script with ffmpeg
# author: Jorge Ramírez <jorgeramirez1990 at gmail dot com>
# help: ./record-screen.sh <record-name>
DEST_DIR=./recordings
if [ ! -d "$DEST_DIR" ]; then
mkdir -p $DEST_DIR
fi
ffmpeg -f x11grab -r 10 -s 1366x768 -i :0.0 -f alsa -i pulse -vcodec libx264 -preset ultrafast -crf 0 -threads 0 $DEST_DIR/$1.mkv
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment