28 lines
512 B
Bash
28 lines
512 B
Bash
#!/bin/bash
|
|
|
|
# Set the video format
|
|
VCODEC="copy"
|
|
|
|
# Set the video bitrate for the final file
|
|
VBITRATE="1200k"
|
|
|
|
# Set framesize for the final file
|
|
VSIZE="hd720"
|
|
|
|
# Set the audio format
|
|
ACODEC="ac3"
|
|
|
|
# Set the audio bitrate for the final file
|
|
ABITRATE="384k"
|
|
|
|
# How many threads should we fire off?
|
|
THREADS=4
|
|
|
|
|
|
|
|
|
|
for i in "$@"; do
|
|
FILENAME=$i
|
|
BASENAME=${FILENAME%.*}
|
|
ffmpeg -i "$FILENAME" -vcodec $VCODEC -s $VSIZE -sameq -acodec $ACODEC -ac 2 -ab $ABITRATE -threads $THREADS "$BASENAME.mp4"
|
|
done
|