I am trying to get this ffmpeg command right, and think I am close but not quite there. I have a source that has 4 stereo pairs in it (RTSP), so the source looks like this in ffmpeg:
Input #0, sdp, from '/tmp/sdp': Duration: N/A, start: 0.000000, bitrate: N/A Stream #0:0: Video: h264 (Main), yuv420p(progressive), 1280x720, 30 fps, 30 tbr, 90k tbn, 60 tbc Stream #0:1: Audio: aac (LC), 48000 Hz, stereo, fltp Stream #0:2: Audio: aac (LC), 48000 Hz, stereo, fltp Stream #0:3: Audio: aac (LC), 48000 Hz, stereo, fltp Stream #0:4: Audio: aac (LC), 48000 Hz, stereo, fltp
And what I want to do is output a single RTMP stream with 7.1 audio. This is what I have so far (just a command fragment to leave off the output url):
ffmpeg -protocol_whitelist file,udp,rtp -threads 4 -loglevel info -i /tmp/sdp -filter_complex '[0:1][0:2][0:3][0:4]join=inputs=8:channel_layout=7.1[a]' -map 0:0 -map '[a]:1' -c:v copy -c:a aac -b:a 384k -ac 8 -ar 44100 -f flv
In the output it throws:
Cannot find a matching stream for unlabeled input pad 4 on filter Parsed_join_0
What am I missing?