scripts/encode_*.sh: used for Datenspuren 2012

This commit is contained in:
Astro 2012-11-12 00:03:59 +01:00
parent 3d861ca51a
commit 9744c4475c
3 changed files with 10 additions and 18 deletions

View File

@ -1,7 +1,7 @@
#!/bin/sh
if=$1
of=`basename "$if"|sed -e 's/\..\+//'`
of=$2
ffmpeg -i "$if" -ss 10 -r 0.002 -b 100k -bt 100M -s 512x288 "$of.%05d.jpg" && \
ffmpeg -i "$if" -ss 10 -r 0.002 -b 100k -bt 100M -s 320x180 "$of.%05d.jpg" && \
convert -delay 50 -loop 0 "$of.?????.jpg" "$of.gif"

View File

@ -1,25 +1,15 @@
#!/bin/sh -e
if=$1
of=`basename "$1"`".mp4"
of=$2
# No. CPU cores:
threads=2
threads=8
# Video bitrate:
vb=400k
# Audio bitrate:
ab=96k
ab=64k
ffmpeg -i "$if" \
-f mp4 \
-an \
-threads $threads \
-vcodec libx264 \
-vpre libx264-ipod640 \
-b:v $vb \
-pass 1 \
-passlogfile "$of.ffmpeg2pass" \
-y /dev/null
ffmpeg -i "$if" \
-f mp4 \
-acodec libfaac \
@ -28,7 +18,7 @@ ffmpeg -i "$if" \
-vcodec libx264 \
-vpre libx264-ipod640 \
-b:v $vb \
-pass 2 \
-s 640x360 \
-passlogfile "$of.ffmpeg2pass" \
-y "$of"

View File

@ -2,10 +2,10 @@
if=$1
of=`basename "$1"`".webm"
of=$2
# No. CPU cores:
threads=2
threads=8
# Video bitrate:
vb=400k
# Audio bitrate:
@ -17,6 +17,7 @@ ffmpeg -i "$if" \
-an \
-vcodec libvpx \
-b:v $vb \
-s 640x360 \
-pass 1 \
-passlogfile "$of.ffmpeg2pass" \
-y /dev/null
@ -27,6 +28,7 @@ ffmpeg -i "$if" \
-ab $ab \
-vcodec libvpx \
-b:v $vb \
-s 640x360 \
-pass 2 \
-passlogfile "$of.ffmpeg2pass" \
-y "$of"