Opened 5 years ago

Closed 5 years ago

#1328 closed enhancement (wontfix)

image2 demuxer to support file list

Reported by: burek Owned by:
Priority: wish Component: avformat
Version: unspecified Keywords: image2
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Is it a big hassle to modify the image2 demuxer to support a text file at the input (instead of image name format with %d) which will tell ffmpeg where from to read image file names?

For example, something like this would be perfect:

ffmpeg -f image2 -i list.txt ... output.avi

FFmpeg could recognize the extension (or do some other kind of recognition) for text file, containing the list of images to process.

Change History (6)

comment:1 Changed 5 years ago by cehoyos

How should FFmpeg / libavformat know that list.txt is not an image in your example command line?

comment:2 follow-ups: Changed 5 years ago by burek

As far as I can see, img2.c uses av_str2id() to guess the image format, based on the file extension, so it might me implemented the same way? If the file has an extension of ".txt" or ".lst", ".pls", ".m3u"... then ffmpeg can read the "playlist" and get the input files from it.

Maybe the most intuitive way would be to use playlist extensions (m3u, pls, ...). My personal choice would be .m3u because of its simplicity (each line represents path to a file and lines beginning with # are comments: http://en.wikipedia.org/wiki/M3U

comment:3 in reply to: ↑ 2 Changed 5 years ago by saste

  • Component changed from undetermined to avformat
  • Keywords image2 added
  • Status changed from new to open

Replying to burek:
[...]

Maybe the most intuitive way would be to use playlist extensions (m3u, pls, ...). My personal choice would be .m3u because of its simplicity (each line represents path to a file and lines beginning with # are comments: http://en.wikipedia.org/wiki/M3U

Can't you use the concat demuxer for that?

comment:3 in reply to: ↑ 2 Changed 5 years ago by saste

  • Component changed from undetermined to avformat
  • Keywords image2 added
  • Status changed from new to open

Replying to burek:
[...]

Maybe the most intuitive way would be to use playlist extensions (m3u, pls, ...). My personal choice would be .m3u because of its simplicity (each line represents path to a file and lines beginning with # are comments: http://en.wikipedia.org/wiki/M3U

Can't you use the concat demuxer for that?

comment:4 Changed 5 years ago by burek

hmh, I was never aware it can be done that way. Could you please suggest a sample command line to achieve this same thing with concat demuxer?

comment:5 Changed 5 years ago by cehoyos

  • Resolution set to wontfix
  • Status changed from open to closed

Since the concat demuxer supports this kind of input list - see http://ffmpeg.org/ffmpeg-formats.html#concat - I don't think the image2 demuxer will get this additional feature.

Note: See TracTickets for help on using tickets.