Skip to content

Instantly share code, notes, and snippets.

@aerostitch
Last active October 17, 2018 07:23
Show Gist options
  • Save aerostitch/d8f95f17b0b4954e430a460a8ac78766 to your computer and use it in GitHub Desktop.
Save aerostitch/d8f95f17b0b4954e430a460a8ac78766 to your computer and use it in GitHub Desktop.
# records from the webcam and my bass pedal
ffmpeg -f v4l2 -thread_queue_size 512 -i /dev/video0 -thread_queue_size 512 \
-f alsa -i hw:1,0 -c:v copy -c:a copy \
${HOME}/Videos/$(date +%Y%m%d%H%M)_record.mkv
# ffmpeg -f v4l2 -thread_queue_size 512 -i /dev/video0 \
# -thread_queue_size 512 \
# -f alsa -i hw:1,0 \
# -vcodec libx264 -x264opts keyint=60:no-scenecut -preset fast \
# -q:v 4 -s 640x480 -r 30 /
# -acodec libmp3lame -q:a 7 -channels 2 \
# ${HOME}/Videos/$(date +%Y%m%d%H%M)_record.mkv
# Get an external camera to be seen as a webcam:
# gphoto2 --stdout --capture-movie | ffmpeg -i - -c:v rawvideo -pix_fmt yuyv422 -deinterlace -threads 0 -f v4l2 /dev/video2
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment