/* ffmpeg */

This commit is contained in:
Astro 2015-06-08 20:52:15 +00:00
parent 382b32d293
commit 617ab6d084
1 changed files with 93 additions and 0 deletions

View File

@ -21,6 +21,99 @@ Zunächst steht im HQ noch kein Aufzeichnungsgerät direkt zur Verfügung, wir s
== Erstellung ==
=== [http://ffmpeg.org/ ffmpeg] ===
==== Allgemeine Optionen ====
{|border=1
!Parameter
!Beschreibung
|-
| -s 720x404
|Rescale
|-
| -r 25
|Framerate
|-
| -ac 1
|Mono-Downmix
|-
| -vf hqdn3d=0:0:16:14
|Denoise: spatial luma, spatial chroma, temporal luma, temporal chroma
|}
''$if'' ist der Input-Filename, ''$of'' ist der Output-Filename.
''$threads'' auf Anzahl der CPU-Kerne setzen. Nicht alle Codecs sind parallelisiert und u.U. ist der Speedup bzw. das Resultat nicht optimal. Wenn man sowieso mehrere Encodings macht, kann man diese auch parallel auf je 1 CPU starten.
Für Bitraten gilt:
* H264 braucht weniger als VP8
* AAC braucht weniger als Vorbis
==== MP4 ====
<pre>
ffmpeg -i "$if" \
-f mp4 \
-acodec libfaac \
-ab 96k \
-threads $threads \
-vcodec libx264 \
-b:v 400k \
-profile:v baseline -level 3.0 \
-movflags +faststart \
-y "$of"
</pre>
==== WebM ====
2-Pass, Bildparameter sollten in beiden Pässen übereinstimmen! 1. Pass dank ''-an'' ohne Audio.
<pre>
ffmpeg -i "$if" \
-threads $threads \
-f webm \
-an \
-vcodec libvpx \
-b:v 600k \
-pass 1 \
-passlogfile "$of.ffmpeg2pass" \
-y /dev/null
ffmpeg -i "$if" \
-threads $threads \
-f webm \
-acodec libvorbis \
-ab 128k \
-ac 1 \
-vcodec libvpx \
-b:v 600k \
-pass 2 \
-passlogfile "$of.ffmpeg2pass" \
-y "$of"
</pre>
==== MP3 Audio-only ====
<pre>
ffmpeg -i "$if" \
-f mp3 \
-ab 128k \
-threads $threads \
-y "$of"
</pre>
==== GIF/JPEG ====
Für Vorschaubildchen
<pre>
ffmpeg -i "$if" -r 0.005 -b:v 100k -bt:v 10M -s 320x180 "$of.%05d.jpg" && \
rm -v $of.0000[01].jpg && \
convert -delay 50 -loop 0 "$of.?????.jpg" "$of.gif" && \
mv $of.00005.jpg $of.jpg && \
rm -v $of.0*.jpg
</pre>
=== [[w:de:how-to|how-to]] ===
<!-- vorbereiteter Abschnitt für /rob -->
* [https://auphonic.com/ auphonic]