[FFmpeg-user] image2 examples missing `-f image2`, can that be right?

Jim DeLaHunt from.ffmpeg-user at jdlh.com
Sun Jan 7 20:16:55 EET 2018

On 2018-01-07 00:48, Gyan Doshi wrote:
> On 1/7/2018 12:38 PM, Jim DeLaHunt wrote:
>> Those examples lack a `-f image2` option. I would expect that option 
>> to be there; after all, isn't the image2 format exactly what this 
>> section is trying to explain?
> FFmpeg probes the input to determine its format. Adding the `-f` 
> option for an input forces the use of that demuxer e.g.
> with a MKV renamed to MP4, running
>     ffmpeg -i in.mp4
> will still result in FFmpeg recognizing it as a Matroska file.
> but
>     ffmpeg -f mp4 -i in.mp4
> will force the MP4 demuxer, and FFmpeg will throw an error.

Fair enough for FFmpeg in general.

And the term "demuxer" may be complicating things. The documentation for 
`image2` describes it as a "demuxer"[1]. But elsewhere, I think the 
FFmpeg documentation describes the operation of extracting multiple 
still frames from a video as "demuxing"[2][4], and the complementary 
operation of merging multiple still frames files into a video as 
"muxing"[3]. I'm not sure what to make of that.

Maybe `image2` should actually be described as a "muxer"?

But my question is about the examples from section 20.9.1 Examples[1], 
documenting the `-f image2` option. The input format is not something like:

      ffmpeg -i in.mp4

It is a template for filenames of still images:

    ffmpeg -i 'img-%03d.jpeg' out.mkv

So, for the case when we use ffmpeg to merge still image files into a 
video file, should the `-f image2` option be required?  And /in this 
section/, which examples illustrating the use of the `-f image2` option, 
is it really correct that the examples do not include `-f image2`?

[1] http://ffmpeg.org/ffmpeg-all.html#image2-1
[2] http://ffmpeg.org/ffmpeg-all.html#Detailed-description
[3] http://ffmpeg.org/ffmpeg-all.html#Demuxers
[4] http://ffmpeg.org/ffmpeg-all.html#Muxers
[5] http://ffmpeg.org/ffmpeg-all.html#Examples-6

      —Jim DeLaHunt, Vancouver, Canada

     --Jim DeLaHunt, jdlh at jdlh.com     http://blog.jdlh.com/ (http://jdlh.com/)
       multilingual websites consultant

       355-1027 Davie St, Vancouver BC V6E 4L2, Canada
          Canada mobile +1-604-376-8953

More information about the ffmpeg-user mailing list