I can’t work out why I get the invalid stream specifier. Here’s what I’m trying to do
Input file
- Stream 0:0: video stream (I am transcoding this to h.264.)
- Stream 0:1: 5.1 AC3 (I am transcoding this to 5.1 AAC.)
- Stream 0:2: AAC stereo track commentary (I want to copy this.)
- Stream 0:3: subtitle track for the movie (I want to copy this.)
- Stream 0:4: subtitle track for director commentary (I want to copy this.)
Command:
ffmpeg -i guard.mkv -c:v libx264 -crf 17 -c:0:a:0 aac -cutoff 20000 -ac 6 -b:a 512K -c:0:a:1 copy -c:s copy guard1-1.mkv
I also tried the below command but it ended up encoding as the default Vorbis instead of AAC. I can’t work out why either:
ffmpeg -i guard.mkv -c:v libx264 -crf 17 -map 0 -c:a:1 aac -cutoff 20000 -ac 6 -b:a 512K -c:a:2 copy -c:s copy guard1-1.mkv
If someone could suggest the correct command with an explainer of where I went wrong I can improve for next time!