echo Provide the time delay for when the fade in should appear (should be 10 seconds before end of video) ffmpeg -fflags +genpts -r 59.94 -i %1 -ss %2 -to %3 -c:v copy -video_track_timescale 60000 -map 0:1 -map 0:0 -ac 2 %6 ffmpeg -i %6 -loop 1 -i %5 -filter_complex "[0]afade=out:st=%4:d=10;[1]format=yuva420p,scale=-1:1080,fade=in:st=%4:d=5:alpha=1[i];[0][i]overlay=(main_w-overlay_w)/2:(main_h-overlay_h)/2:shortest=1" -c:v libx264 final_%6