Recorder for 2 HDMI Signals into MP4/MKV with 2 Video Tracks
FFMPEG takes 2 -i input options (can a capture device) and uses -map to select the input streams then uses -program to define program name and -st to define output streams to a output file. i.e.
!ffmpeg -y -i https://mkvtoolnix.download/samples/vsshort-vorbis-subs.mkv \
-i https://github.com/Matroska-Org/matroska-test-files/raw/master/test_files/test5.mkv \
-map 0:0 -map 0:1 -map 0:2 -map 0:3 \
-map 1:0 -map 1:1 -map 1:2 -map 1:3 -map 1:4 -map 1:5 -map 1:6 -map 1:7 -map 1:8 \
-program title=vsshort-vorbis-subs:st=0:st=1:st=2:st=3 \
-program title=test5:st=4:st=5:st=6:st=7:st=8:st=9:st=10st=11:st=12 \
 -c:s copy mpts.mkv