#!/bin/bash
for i in $( ls | grep 2015 ); do
	ffmpeg -i $i/cam1.mp4 -i $i/cam2.mp4 -i $i/cam3.mp4 -filter_complex "nullsrc=size=1280x960 [base]; [0:v] setpts=PTS-STARTPTS, scale=640x480 [upperright]; [1:v] setpts=PTS-STARTPTS, scale=640x480 [lowerleft]; [2:v] setpts=PTS-STARTPTS, scale=640x480 [lowerright]; [base][upperright] overlay=shortest=1:x=640 [tmp1]; [tmp1][lowerleft] overlay=shortest=1:x=0:y=480 [tmp2]; [tmp2][lowerright] overlay=shortest=1:x=640:y=480" -c:v libx264 -an $i/multi.mp4
done
