[FFmpeg-user] Dual Language in Satellite TV

Bhikkhu Mettavihari tv.lists at gmail.com
Sat Mar 8 09:02:23 CET 2014


Greetings

> I run several Educational Channels via  a local Satellite
> > in *one* of our local Languages.
> > I have been given the challenge to generate the same
> > program in 2 languages.
>
> > This should be done in a way that the Television receiver
> > can switch from language 1 to language 2 at his choice.
>
> > Our present production is done fully in Linux and the
> > final product is compressed using ffmpeg.
>
> Please provide your current ffmpeg command line (including
> console output), it should be trivial to add an additional
> audio track.
>

That sounds great, Thank you.

This is my script,
or shall I say this is the part of the script that generate the 512k file
that we use for the TV

much of the full file is of cause not all relevant since it is designed for
compressing 4 files and one image.
I have cut out the other part.
========================
#!/bin/bash
# a script that outputs to dvd-video with ffmpeg,
# a script that outputs to net-video with ffmpeg,

# defining some variables
path1=

filename=


filen=$(echo $filename | cut -d. -f1)
ext=$(echo $filename | cut -d. -f2)
file1=$(echo $filen | sed 's/\(.*\)/\L\1/')

file1p1=$file1-a
file1p2=$file1-b
file1p3=$file1-c


#2pass hq ffmpeg mp4 512k file
ffmpeg -i $file1.$ext \
-pass 1 -vcodec libx264 -preset fast -b 512k -minrate 512k -maxrate 512k
-bufsize 512k -threads 0 -f mp4 -an -y /dev/null && \
ffmpeg -i $file1.$ext -pass 2 -acodec libfaac -ab 128k -ac 2 -vcodec
libx264 \
-preset fast -b 512k -minrate 512k -maxrate 512k -bufsize 512k -threads 0
-f mp4 $file1.temp.mp4

sleep 30
rm *.log*

qt-faststart $file1.temp.mp4 $file1-512k.mp4
rm $file1.temp.mp4
===============================
This all works fine with just 1 stereo track in the video.

I guess this is what you asked for.
I am fine with rebuilding to the latest version from git if needed.

editor at mettavihari:~$ ffmpeg
ffmpeg version git-2012-05-02-b197c1c Copyright (c) 2000-2012 the FFmpeg
developers
  built on May  2 2012 16:36:36 with gcc 4.6.3
  configuration: --enable-gpl --enable-libfaac --enable-libmp3lame
--enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libtheora
--enable-libvorbis --enable-libvpx --enable-libx264 --enable-nonfree
--enable-version3 --enable-x11grab
  libavutil      51. 49.100 / 51. 49.100
  libavcodec     54. 17.101 / 54. 17.101
  libavformat    54.  3.100 / 54.  3.100
  libavdevice    53.  4.100 / 53.  4.100
  libavfilter     2. 72.102 /  2. 72.102
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 11.100 /  0. 11.100
  libpostproc    52.  0.100 / 52.  0.100
Hyper fast Audio and Video encoder
usage: ffmpeg [options] [[infile options] -i infile]... {[outfile options]
outfile}...

Use -h to get full help or, even better, run 'man ffmpeg'


Thank you for the positive attitude.

Mettavihari


More information about the ffmpeg-user mailing list