c3d2-web/scripts/encode_mp4.sh

24 lines
312 B
Bash
Executable File

#!/bin/sh -e
if=$1
of=$2
# No. CPU cores:
threads=8
# Video bitrate:
vb=400k
# Audio bitrate:
ab=128k
ffmpeg -i "$if" \
-f mp4 \
-acodec libfaac \
-ab $ab \
-threads $threads \
-vcodec libx264 \
-vpre libx264-ipod640 \
-b:v $vb \
-passlogfile "$of.ffmpeg2pass" \
-y "$of"