[FFmpeg-user] Dropping audio streams confuses vlc?
Andrey Aleksandrovich
andrey.aleksandrovich at googlemail.com
Mon Apr 1 18:45:06 CEST 2013
On 4/1/13, hcoin <hcoin at quietfountain.com> wrote:
> Hi all, thanks for ffmpeg!
>
> I'm struggling to drop two of three audio streams from an mpeg2
> audio+video source, and can't puzzle out my mistake.
>
> I've given the following command on a mpeg2 file with one video and
> three ac3 audio streams. The source and all three streams play
> perfectly on vlc. I want the result to be exactly what was input,
> except with one audio stream: only the second of the three in the
> original. But, when I give the command the result is a file which when
> played in vlc shows around 56 or so audio streams, and otherwise
> produces no sound whatever, though the picture is correct. Am I making
> some newbie mistake?
>
> ffmpeg -i sourcevid.mpg -vcodec copy -acodec copy outvid.mpg -map 0.0
> -map 0.2
>
> ffmpeg -i sourcevid.mpg -vcodec copy -acodec copy outvid.mpg -map 0.0
> -map 0.2 -ac 1
>
> Both cases process normally, showing the entire and correct length, then
> exiting. Yet - no sound on playback.
>
> I tried it on freebsd 9.1 release, and I tried it on debian wheezy (0:0
> and 0:2 instead of 0.0 and 0.2) -- same result. What have I overlooked?
>
> Thanks!
>
> Harry
Try this:
ffmpeg -i INPUT.file -vcodec copy -acodec copy -map 0:0 -map 0:2 OUTPUT.file
More information about the ffmpeg-user
mailing list