[FFmpeg-user] really simple pan= question

Paul Miller listmail at voltar-confed.org
Tue May 8 16:58:57 CEST 2012


On Tue, May 08, 2012 at 02:40:43PM +0000, Carl Eugen Hoyos wrote:
> Complete, uncut console output missing.

Ahh, ok...  Did you want all six?

ffmpeg version 0.10.2 Copyright (c) 2000-2012 the FFmpeg developers
  built on Mar 17 2012 08:51:02 with gcc 4.6.3
  configuration: --prefix=/usr --enable-libmp3lame --enable-libvorbis --enable-libxvid --enable-libx264 --enable-libvpx --enable-libtheora --enable-libgsm --enable-libspeex --enable-postproc --enable-shared --enable-x11grab --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libschroedinger --enable-libopenjpeg --enable-librtmp --enable-libpulse --enable-gpl --enable-version3 --enable-runtime-cpudetect --disable-debug --disable-static
  libavutil      51. 35.100 / 51. 35.100
  libavcodec     53. 61.100 / 53. 61.100
  libavformat    53. 32.100 / 53. 32.100
  libavdevice    53.  4.100 / 53.  4.100
  libavfilter     2. 61.100 /  2. 61.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0.  6.100 /  0.  6.100
  libpostproc    52.  0.100 / 52.  0.100
Input #0, matroska,webm, from 'short.mkv':
  Metadata:
    ENCODER         : Lavf53.32.100
  Duration: 00:01:30.12, start: 0.000000, bitrate: 15723 kb/s
    Stream #0:0: Video: h264 (High), yuv420p, 1920x1080, SAR 1:1 DAR 16:9, 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (default)
    Metadata:
      title           : Tron.Legacy.3D.2010.ENG.DTS.1080p.3DBD.x264.half.SBS.z-man
    Stream #0:1(eng): Audio: dts (DTS), 48000 Hz, 5.1(side), s16, 1536 kb/s (default)
Output #0, mp3, to 'c5.mp3':
  Metadata:
    TSSE            : Lavf53.32.100
    Stream #0:0(eng): Audio: mp3, 48000 Hz, 1 channels, s16, 128 kb/s (default)
Stream mapping:
  Stream #0:1 -> #0:0 (dca -> libmp3lame)
Press [q] to stop, [?] for help
size=     398kB time=00:00:25.44 bitrate= 128.1kbits/s    


> But please decide if you want to use pan or -ac 1 since -ac 1
> makes sure the dts decoder outputs mono (which cannot be
> changed by pan in any way).

I don't understand what this means and the docs are unclear on
the implications of using -filter:a with -ac.  If I leave off -ac
1 and try to use (eg) -filter:a aconvert=stereo:pan=blarg then
ffmpeg tries to stuff 5.1 audio into an mp3, which doesn't work.


ffmpeg -i short.mkv -strict experimental -filter:a pan=1:c0=c0 -y c0.mp3
ffmpeg version 0.10.2 Copyright (c) 2000-2012 the FFmpeg developers
  built on Mar 17 2012 08:51:02 with gcc 4.6.3
  configuration: --prefix=/usr --enable-libmp3lame --enable-libvorbis --enable-libxvid --enable-libx264 --enable-libvpx --enable-libtheora --enable-libgsm --enable-libspeex --enable-postproc --enable-shared --enable-x11grab --enable-libopencore_amrnb --enable-libopencore_amrwb --enable-libschroedinger --enable-libopenjpeg --enable-librtmp --enable-libpulse --enable-gpl --enable-version3 --enable-runtime-cpudetect --disable-debug --disable-static
  libavutil      51. 35.100 / 51. 35.100
  libavcodec     53. 61.100 / 53. 61.100
  libavformat    53. 32.100 / 53. 32.100
  libavdevice    53.  4.100 / 53.  4.100
  libavfilter     2. 61.100 /  2. 61.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0.  6.100 /  0.  6.100
  libpostproc    52.  0.100 / 52.  0.100
Input #0, matroska,webm, from 'short.mkv':
  Metadata:
    ENCODER         : Lavf53.32.100
  Duration: 00:01:30.12, start: 0.000000, bitrate: 15723 kb/s
    Stream #0:0: Video: h264 (High), yuv420p, 1920x1080, SAR 1:1 DAR 16:9, 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (default)
    Metadata:
      title           : Tron.Legacy.3D.2010.ENG.DTS.1080p.3DBD.x264.half.SBS.z-man
    Stream #0:1(eng): Audio: dts (DTS), 48000 Hz, 5.1(side), s16, 1536 kb/s (default)
[libmp3lame @ 0x16827c0] Invalid number of channels 6, must be <= 2
Output #0, mp3, to 'c0.mp3':
  Metadata:
    ENCODER         : Lavf53.32.100
    Stream #0:0(eng): Audio: mp3, 48000 Hz, 5.1(side), s16, 128 kb/s (default)
Stream mapping:
  Stream #0:1 -> #0:0 (dca -> libmp3lame)
Error while opening encoder for output stream #0:0 - maybe incorrect parameters such as bit_rate, rate, width or height

> makes sure the dts decoder outputs mono (which cannot be

This is actually what I want.  I thought the for loop made it
clear that I'm trying to put each channel in its own file.  If
this is not clear from the for loop then there's obviously
something wrong with my syntax and my understanding of how this
program operates.

-Paul

-- 
If riding in an airplane is flying, then riding in a boat is swimming.
116 jumps, 48.6 minutes of freefall, 92.9 freefall miles.


More information about the ffmpeg-user mailing list