[FFmpeg-devel] [PATCH] doc: document amerge filter as an alternative for the -map_channel limitation.

Clément Bœsch ubitux at gmail.com
Tue Jan 10 11:52:02 CET 2012


From: Clément Bœsch <clement.boesch at smartjog.com>

---
 doc/ffmpeg.texi |   19 +++++++++++++++++++
 1 files changed, 19 insertions(+), 0 deletions(-)

diff --git a/doc/ffmpeg.texi b/doc/ffmpeg.texi
index 83a45a8..f4df331 100644
--- a/doc/ffmpeg.texi
+++ b/doc/ffmpeg.texi
@@ -833,6 +833,25 @@ possible, for example, to turn two separate mono streams into a single stereo
 stream. However spliting a stereo stream into two single channel mono streams
 is possible.
 
+If you need this feature, a possible workaround is to use the @emph{amerge}
+filter. For example, if you need to merge a media (here @file{input.mkv}) with
+6 mono audio streams into one single 5.1 channel audio stream:
+
+ at example
+ffmpeg -f lavfi -i "
+amovie=input.mkv:si=0 [a0];
+amovie=input.mkv:si=1 [a1];
+amovie=input.mkv:si=2 [a2];
+amovie=input.mkv:si=3 [a3];
+amovie=input.mkv:si=4 [a4];
+amovie=input.mkv:si=5 [a5];
+[a0][a1] amerge [x0];
+[x0][a2] amerge [x1];
+[x1][a3] amerge [x2];
+[x2][a4] amerge [x3];
+[x3][a5] amerge" -c:a pcm_s16le output.mkv
+ at end example
+
 @item -map_metadata[:@var{metadata_type}][:@var{index}] @var{infile}[:@var{metadata_type}][:@var{index}] (@emph{output,per-metadata})
 Set metadata information of the next output file from @var{infile}. Note that
 those are file indices (zero-based), not filenames.
-- 
1.7.7.3



More information about the ffmpeg-devel mailing list