[FFmpeg-user] 2 channels ?

Moritz Barsnick barsnick at gmx.net
Mon Jul 18 00:33:53 EEST 2016


On Sun, Jul 17, 2016 at 23:08:23 +0200, Jens Kallup wrote:
> is it possible to create 2 channels for 2 different languages
> in one file, prefered mp3/4 ?

In ffmpeg-speak, those are separate streams. The word "channel" is used
for components of one stream, such as stereo or 5.1.

Yes, sure it can be done. But an MP3 file can only hold one stream, so
you need to use a different container format, such as your suggested
MP4.

Just map multiple audio inputs to ffmpeg, it will place the
corresponding outputs into the resulting container:

$ ffmpeg -i video -i audio1 -i audio2 -map 0 -map 1 -map 2 output.mp4
(Don't forget to add your relevant options. ;-))

You can even tell the output what those languages are, by using the
proper metadata:

  [...] -metadata:s:a:0 language=eng -metadata:s:a:1 language=deu

Moritz


More information about the ffmpeg-user mailing list