I am working on an IP-SDI decoder using ffmpeg and a Blackmagic Decklink Mini Monitor card.
If I list ffmpeg supported output modes with this command:
ffmpeg -i test_1.mp4 -f decklink -list_formats 1 'DeckLink Mini Monitor'
I get these:
[decklink @ 0x39b8c60] Supported formats for 'DeckLink Mini Monitor':
[decklink @ 0x39b8c60] 1 720x486 at 30000/1001 fps (interlaced, lower field first)
[decklink @ 0x39b8c60] 2 720x486 at 24000/1001 fps
[decklink @ 0x39b8c60] 3 720x576 at 25000/1000 fps (interlaced, upper field first)
[decklink @ 0x39b8c60] 4 720x486 at 60000/1001 fps
[decklink @ 0x39b8c60] 5 720x576 at 50000/1000 fps
[decklink @ 0x39b8c60] 6 1920x1080 at 24000/1001 fps
[decklink @ 0x39b8c60] 7 1920x1080 at 24000/1000 fps
[decklink @ 0x39b8c60] 8 1920x1080 at 25000/1000 fps
[decklink @ 0x39b8c60] 9 1920x1080 at 30000/1001 fps
[decklink @ 0x39b8c60] 10 1920x1080 at 30000/1000 fps
[decklink @ 0x39b8c60] 11 1920x1080 at 25000/1000 fps (interlaced, upper field first)
[decklink @ 0x39b8c60] 12 1920x1080 at 30000/1001 fps (interlaced, upper field first)
[decklink @ 0x39b8c60] 13 1920x1080 at 30000/1000 fps (interlaced, upper field first)
[decklink @ 0x39b8c60] 14 1280x720 at 50000/1000 fps
[decklink @ 0x39b8c60] 15 1280x720 at 60000/1001 fps
[decklink @ 0x39b8c60] 16 1280x720 at 60000/1000 fps
Ok. I can set my desired output format using -s for output size and -r for frame rate:
/home/ffmpeg/bin/ffmpeg \
-i udp://224.168.240.69:2069?buffer_size=262144?fifo_size=4525000&overrun_nonfatal=1 \
-threads 0 -vf setpts=PTS-STARTPTS \
-pix_fmt uyvy422 \
-c:a pcm_s16le -ac 2 -ar 48000 \
-s 1920x1080 -r 30000/1000 \
-f decklink DeckLink Mini Monitor
Is there a way to set my desired output format using ffmpeg's Supported number from the list [1..16]?