|
|
|
@ -1,4 +1,4 @@
|
|
|
|
while getopts "s:b:" opt; do
|
|
|
|
while getopts "s:b:r:" opt; do
|
|
|
|
case ${opt} in
|
|
|
|
case ${opt} in
|
|
|
|
s )
|
|
|
|
s )
|
|
|
|
height=$OPTARG
|
|
|
|
height=$OPTARG
|
|
|
|
@ -6,6 +6,9 @@ while getopts "s:b:" opt; do
|
|
|
|
b )
|
|
|
|
b )
|
|
|
|
videorate=$OPTARG
|
|
|
|
videorate=$OPTARG
|
|
|
|
;;
|
|
|
|
;;
|
|
|
|
|
|
|
|
r )
|
|
|
|
|
|
|
|
fps=$OPTARG
|
|
|
|
|
|
|
|
;;
|
|
|
|
\? )
|
|
|
|
\? )
|
|
|
|
echo "Invalid option: $OPTARG" 1>&2
|
|
|
|
echo "Invalid option: $OPTARG" 1>&2
|
|
|
|
;;
|
|
|
|
;;
|
|
|
|
@ -28,19 +31,28 @@ else
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ -z "$fps" ]
|
|
|
|
|
|
|
|
then
|
|
|
|
|
|
|
|
r=23.976M;
|
|
|
|
|
|
|
|
else
|
|
|
|
|
|
|
|
r=$fps;
|
|
|
|
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if [ -z "$height" ]
|
|
|
|
if [ -z "$height" ]
|
|
|
|
then
|
|
|
|
then
|
|
|
|
for i;
|
|
|
|
for i;
|
|
|
|
do ffmpeg -i "$i" -c:v libx264 -x264opts keyint=$g:scenecut=-1 -profile:v main -pix_fmt yuv420p -q 0 -strict -2 -vb $vb -y "${i%.*}_h264.mp4" ;
|
|
|
|
do ffmpeg -r $r -i "$i" -r $r -c:v libx264 -x264opts keyint=$g:scenecut=-1 -profile:v main -pix_fmt yuv420p -q 0 -strict -2 -vb $vb -y ${i%.*}_h264.mp4 ;
|
|
|
|
done;
|
|
|
|
done;
|
|
|
|
else
|
|
|
|
else
|
|
|
|
width=$(($height*16/9))
|
|
|
|
width=$(($height*16/9))
|
|
|
|
for i;
|
|
|
|
for i;
|
|
|
|
do ffmpeg -i "$i" -s $width'x'$height -c:v libx264 -x264opts keyint=$g:scenecut=-1 -profile:v main -pix_fmt yuv420p -q 0 -strict -2 -vb $vb -y "${i%.*}_"$width"x"$height"_h264.mp4" ;
|
|
|
|
do ffmpeg -r $r -i "$i" -s $width'x'$height -c:v libx264 -x264opts keyint=$g:scenecut=-1 -profile:v main -pix_fmt yuv420p -q 0 -strict -2 -vb $vb -y ${i%.*}_"$width"x"$height"_h264.mp4 ;
|
|
|
|
done;
|
|
|
|
done;
|
|
|
|
|
|
|
|
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#/Volumes/pegasus/01_PROJECTS/18060_DSDC035_25_Days_Of_Christmas_2018/09_Graphics/05_Graphics_Output/01_GFX_Scenes/103018
|
|
|
|
#/Volumes/pegasus/01_PROJECTS/18060_DSDC035_25_Days_Of_Christmas_2018/09_Graphics/05_Graphics_Output/01_GFX_Scenes/103018
|
|
|
|
|
|
|
|
|
|
|
|
get_project_base () {
|
|
|
|
get_project_base () {
|
|
|
|
|