[FFmpeg-user] how to add more than 1 stream of audio to a TS filesetting the language?

Wagner Patriota wagner.patriota at gmail.com
Thu Jun 21 01:41:16 CEST 2012


It only gives me one audio... why?

$ *ffmpeg -i v.m2t -i a-p.aac -i a-f.aac -i s.sub -vcodec copy -acodec copy
-scodec dvbsub -metadata:s:a:0 language=vie -metadata:s:a:1 language=fra
-metadata:s:s:0 language=ger -t 10 -y out.ts*
ffmpeg version N-41608-ge7cd4a5 Copyright (c) 2000-2012 the FFmpeg
developers
  built on Jun 20 2012 19:39:01 with llvm_gcc 4.2.1 (Based on Apple Inc.
build 5658) (LLVM build 2336.9.00)
  configuration: --enable-nonfree --enable-gpl --disable-swscale-alpha
--disable-doc --disable-ffplay --disable-ffprobe --disable-ffserver
--disable-asm
  libavutil      51. 58.100 / 51. 58.100
  libavcodec     54. 25.100 / 54. 25.100
  libavformat    54.  6.101 / 54.  6.101
  libavdevice    54.  0.100 / 54.  0.100
  libavfilter     2. 79.100 /  2. 79.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 15.100 /  0. 15.100
  libpostproc    52.  0.100 / 52.  0.100
[mpegts @ 0x7fd83b83d800] max_analyze_duration 5000000 reached at 5005000
Input #0, mpegts, from 'v.m2t':
  Duration: 01:29:36.73, start: 0.958333, bitrate: 2338 kb/s
  Program 1
    Stream #0:0[0x200]: Video: h264 (High) ([27][0][0][0] / 0x001B),
yuv420p, 720x480 [SAR 40:33 DAR 20:11], 29.97 fps, 29.97 tbr, 90k tbn,
59.94 tbc
[aac @ 0x7fd83b84ae00] max_analyze_duration 5000000 reached at 5015510
[aac @ 0x7fd83b84ae00] Estimating duration from bitrate, this may be
inaccurate
Input #1, aac, from 'a-p.aac':
  Duration: 01:28:18.58, bitrate: 129 kb/s
    Stream #1:0: Audio: aac, 44100 Hz, stereo, s16, 129 kb/s
[aac @ 0x7fd83b851600] max_analyze_duration 5000000 reached at 5015510
[aac @ 0x7fd83b851600] Estimating duration from bitrate, this may be
inaccurate
Input #2, aac, from 'a-f.aac':
  Duration: 01:27:09.26, bitrate: 131 kb/s
    Stream #2:0: Audio: aac, 44100 Hz, stereo, s16, 131 kb/s
Input #3, mpeg, from 's.sub':
  Duration: 01:23:38.11, start: 64.111000, bitrate: 2 kb/s
    Stream #3:0[0x20]: Subtitle: dvd_subtitle
ret 0, stream_spec a:0
ret 0, stream_spec a:1a
ret 1, stream_spec s:0
[mpegts @ 0x7fd83b87da00] muxrate VBR, pcr every 2 pkts, sdt every 200,
pat/pmt every 40 pkts
Output #0, mpegts, to 'out.ts':
  Metadata:
    encoder         : Lavf54.6.101
    Stream #0:0: Video: h264 ([27][0][0][0] / 0x001B), yuv420p, 720x480
[SAR 40:33 DAR 20:11], q=2-31, 29.97 fps, 90k tbn, 29.97 tbc
    Stream #0:1(vie): Audio: aac, 44100 Hz, stereo, 129 kb/s
    Stream #0:2(ger): Subtitle: dvb_subtitle
Stream mapping:
  Stream #0:0 -> #0:0 (copy)
  Stream #1:0 -> #0:1 (copy)
  Stream #3:0 -> #0:2 (dvdsub -> dvbsub)
Press [q] to stop, [?] for help
[mpegts @ 0x7fd83b87da00] Encoder did not produce proper pts, making some
up.
[mpegts @ 0x7fd83b87da00] Using default PTS.
    Last message repeated 110 times
Using default PTS.0 q=-1.0 size=     408kB time=00:00:01.50
bitrate=2212.2kbits/s
[mpegts @ 0x7fd83b87da00] Using default PTS.
    Last message repeated 124 times
Using default PTS.7 q=-1.0 size=     898kB time=00:00:03.20
bitrate=2295.2kbits/s
[mpegts @ 0x7fd83b87da00] Using default PTS.
    Last message repeated 120 times
Using default PTS.7 q=-1.0 size=    1434kB time=00:00:04.87
bitrate=2408.6kbits/s
[mpegts @ 0x7fd83b87da00] Using default PTS.
    Last message repeated 122 times
Using default PTS.7 q=-1.0 size=    1956kB time=00:00:06.54
bitrate=2447.6kbits/s
[mpegts @ 0x7fd83b87da00] Using default PTS.
    Last message repeated 66 times
Using default PTS.9 q=-1.0 size=    2224kB time=00:00:07.47
bitrate=2436.6kbits/s
[mpegts @ 0x7fd83b87da00] Using default PTS.
    Last message repeated 95 times
Using default PTS.7 q=-1.0 size=    2584kB time=00:00:08.80
bitrate=2405.6kbits/s
[mpegts @ 0x7fd83b87da00] Using default PTS.
    Last message repeated 76 times
Using default PTS.4 q=-1.0 size=    2905kB time=00:00:09.84
bitrate=2417.5kbits/s
[mpegts @ 0x7fd83b87da00] Using default PTS.
    Last message repeated 9 times
Using default PTS.
[mpegts @ 0x7fd83b87da00] Using default PTS.
frame=  300 fps= 83 q=-1.0 Lsize=    2952kB time=00:00:10.00
bitrate=2416.4kbits/s
video:2521kB audio:157kB global headers:0kB muxing overhead 10.227924%

On Wed, Jun 20, 2012 at 8:11 PM, Dave Bevan <dave.bevan at bbc.co.uk> wrote:

> >I have:
> >video.ts [only video]
> >english.ts [only audio AAC]
> >french.ts [only audio AAC]
> >
> >I want to have an MPEG-TS file where I can switch the language from
> english
> >to french... very simple... how do I do it?
>
>
> Please supply complete uncut output from:
>
> ffmpeg -i video.ts -i english.ts -i french.ts
>
> --dave.
>
> http://www.bbc.co.uk/
> This e-mail (and any attachments) is confidential and may contain personal
> views which are not the views of the BBC unless specifically stated.
> If you have received it in error, please delete it from your system.
> Do not use, copy or disclose the information in any way nor act in
> reliance on it and notify the sender immediately.
> Please note that the BBC monitors e-mails sent or received.
> Further communication will signify your consent to this.
>
> _______________________________________________
> ffmpeg-user mailing list
> ffmpeg-user at ffmpeg.org
> http://ffmpeg.org/mailman/listinfo/ffmpeg-user
>


More information about the ffmpeg-user mailing list