Search code examples
windowsimage-processingffmpegvideo-processing

Unable to find suitable output format for 'ffmpeg'


I'm trying to use the ffmpeg toolset to stitch a set of images to an .mp4 and am receiving the following error:

[NULL @ 000001d48d1dcc00] Unable to find a suitable output format for 
'ffmpeg' ffmpeg: Invalid argument

The command I'm using is:

ffmpeg -r 30 -f image2 -s 1920x1080 -i C://MYPATH//back_squat_%03d.png -vcodec libx264 -crf 25 -pix_fmt yuv420p C://MYPATH//back_squat.mp4

And the full output looks like this.

ffmpeg version 4.2.3 Copyright (c) 2000-2020 the FFmpeg developers
  built with gcc 9.3.1 (GCC) 20200523
  configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libdav1d --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-libvidstab --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa --enable-libspeex --enable-libxvid --enable-libaom --enable-libmfx --enable-amf --enable-ffnvcodec --enable-cuvid --enable-d3d11va --enable-nvenc --enable-nvdec --enable-dxva2 --enable-avisynth --enable-libopenmpt
  libavutil      56. 31.100 / 56. 31.100
  libavcodec     58. 54.100 / 58. 54.100
  libavformat    58. 29.100 / 58. 29.100
  libavdevice    58.  8.100 / 58.  8.100
  libavfilter     7. 57.100 /  7. 57.100
  libswscale      5.  5.100 /  5.  5.100
  libswresample   3.  5.100 /  3.  5.100
  libpostproc    55.  5.100 / 55.  5.100
Input #0, image2, from 'C://MYPATH//back_squat_%03d.png':
  Duration: 00:00:02.37, start: 0.000000, bitrate: N/A
    Stream #0:0: Video: png, rgba(pc), 900x1000 [SAR 2835:2835 DAR 9:10], 30 fps, 30 tbr, 30 tbn, 30 tbc
Input #1, image2, from 'C://MYPATH//back_squat_%03d.png':
  Duration: 00:00:02.37, start: 0.000000, bitrate: N/A
    Stream #1:0: Video: png, rgba(pc), 900x1000 [SAR 2835:2835 DAR 9:10], 30 fps, 30 tbr, 30 tbn, 30 tbc
[NULL @ 000002001b8d5780] Unable to find a suitable output format for 'ffmpeg'
ffmpeg: Invalid argument

What is wrong with the syntax of the command string?


Solution

  • Maybe someone can explain to me why this question got marked down? It turns out I was missing a '-f mp4' prior to the output path. so the command string should have looked like this in my case.

    ffmpeg -r 30 -f image2 -i C://MYPATH//back_squat_%03d.png -vcodec libx264 -crf 25 -pix_fmt yuv420p -f mp4 C://MYPATH//back_squat.mp4