[FFmpeg-devel] [patch] allow wordexp globs in image2 file sequence import

Michael Niedermayer michaelni
Sun Jan 2 23:39:48 CET 2011

On Sun, Jan 02, 2011 at 08:52:26AM -0500, Brian Olson wrote:
> On Jan 1, 2011, at 10:28 PM, Michael Niedermayer wrote:
> > On Fri, Dec 31, 2010 at 12:11:26PM -0500, Brian Olson wrote:
> >> It seemed cumbersome to me to have to symlink/rename my image sequence files to fit
> >> ffmpeg -i prefix%05d.jpg
> >> so I hacked libavformat/img2.c to use <wordexp.h> file globbing, and now I can
> >> ffmpeg -i '*.jpg'
> >> (and other shell-expnsion patterns like ? * [] {})
> >> 
> >> This is my first attempt at submitting to ffmpeg. I hope you like it. Feedback welcome. Hopefully I didn't break the conventions too much.
> >> 
> >> Brian Olson
> >> http://bolson.org/
> >> 
> > 
> >> img2.c |   63 +++++++++++++++++++++++++++++++++++++++++++++++++++++++--------
> >> 1 file changed, 55 insertions(+), 8 deletions(-)
> >> 27ac4fb6e59175875e0fc3ef0c46f21e3bdfe196  img2_wordexp.diff
> > 
> > is there an advantage in this over using the concat protocol?
> My reading of the concat: protocol is that it would require all the files to be listed sequentially on the command line,

ls, cat, cp, ... need that too

if you would argue concat had a annoying syntax that doesnt integrate nicely
with the shell then id agree but moving shell functionality into applications
is a bit uhm, especially if things like concats syntax is just left inconvenient
and ignored while more hacks to do the same thing are added
also is the needed stuff available on mingw? osx? bsd?
what about the order of elements of a *.jpg list? is it guranteed to be some
useable order or just random luck?

Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

There will always be a question for which you do not know the correct awnser.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20110102/30c75b84/attachment.pgp>

More information about the ffmpeg-devel mailing list