Skip to content

Instantly share code, notes, and snippets.

@Gallefray
Created September 26, 2013 18:52
Show Gist options
  • Save Gallefray/6718845 to your computer and use it in GitHub Desktop.
Save Gallefray/6718845 to your computer and use it in GitHub Desktop.
This is my Screencasting script for Manjaro Linux 0.8.7.1. AFAIK it also works on Arch Linux. Taken from this comment on YouTube: http://www.youtube.com/watch?v=BuKo0l3ZfEE&lc=KerskmjLKoaYF2fLbc9FmUvi3eDASKddJ_OA63puF7Y Modified slightly to make it extensible.
#!/bin/zsh
audiochannels=2
fps=15
inres=1280x1024
audiocodec=pcm_s16le
videocodec=libx264
preset=ultrafast
threads=0
outfile=output.mkv
ffmpeg -f alsa -ac $audiochannels -i default -f x11grab -r $fps -s $(xwininfo -root | grep 'geometry' | awk '{print $2;}') -s $inres -i :0.0 -acodec $audiocodec -vcodec $videocodec -preset $preset -threads $threads $outfile
@Gallefray
Copy link
Author

This could probably be adapted for streaming by changing the audio codec and the output file :D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment