Daniel's Weblog
Posts Tags Colophon
About

My go to commands for processing GoPro footage (or really any video) with ffmpeg:

  1. Merge all mp4 files in to a single file without reencoding the whole thing (Small amount of reencoding occurs where the clips are joined):

    This is very useful on computers without powerful GPUs (older computers or in my case my Synology NAS)!

    Note that all clips need to be recorded with the same settings

ffmpeg -f concat -safe 0 -i <(for f in GX*.MP4; do echo "file '$PWD/$f'"; done) -c copy output.mp4
  1. Compress all files in a directory:
for i in GX*.MP4; do ffmpeg -i "$i" -c:a copy -c:v h264 -crf 22 "${i%.}_lowres.mp4"; done
  1. Extract audio from a video file:
ffmpeg -i $1 -vn -acodec copy "${1%.*}.aac"