gorecord foo.mp4
I've tried all of the screen recorders available for Linux and this is easily the best. xvidcap segfaults; VNC is too much hassle. There are alternatives of this command already here that I am just too lazy to reply to. Messing with the frames per second option, -r, 25 seems to be the best. Any lower and the video will look like a flipbook, if it records at all - -r 10 won't - any faster is the same, oddly enough.
Edit: CLF doesn't like my long command to add audio, so here it is in the description.
goaddaudio()
{
if [ $# != 3 ]; then
echo 'goaddaudio < audio > < src video > < dst video >'
return
fi
f=goaddaudio$RANDOM
ffmpeg -i "$2" &> $f
d=$( grep Duration $f | awk '{print $2}' | tr -d ',' ) &&
rm $f &&
ffmpeg -i "$1" -i "$2" -r 25 -ab 192k -ar 44100 -sameq -t $d "$3"
}
Any thoughts on this command? Does it work on your machine? Can you do the same thing with only 14 characters?
You must be signed in to comment.
commandlinefu.com is the place to record those command-line gems that you return to again and again. That way others can gain from your CLI wisdom and you from theirs too. All commands can be commented on, discussed and voted up or down.
Every new command is wrapped in a tweet and posted to Twitter. Following the stream is a great way of staying abreast of the latest commands. For the more discerning, there are Twitter accounts for commands that get a minimum of 3 and 10 votes - that way only the great commands get tweeted.
» http://twitter.com/commandlinefu
» http://twitter.com/commandlinefu3
» http://twitter.com/commandlinefu10
Use your favourite RSS aggregator to stay in touch with the latest commands. There are feeds mirroring the 3 Twitter streams as well as for virtually every other subset (users, tags, functions,…):
Subscribe to the feed for:
goaddaudio() { if [ $# != 3 ]; then echo "goaddaudio < audio > < src video > < dst video >"; return; fi; f=goaddaudio$RANDOM ffmpeg -i "$2" &> $f d=$( grep Duration $f | awk "{print $2}" | tr -d ',' ) && rm $f && ffmpeg -i "$1" -i "$2" -r 25 -ab 192k -ar 44100 -sameq -t $d "$3" ;}
gorecord() { if [ $# != 1 ]; then echo "gorecord video.mp4"; return; fi; ffmpeg -f x11grab -s 1440x900 -r 25 -i :0.0 -sameq -vcodec mpeg4 "$1" ;}