1

I'd like to make a video of the last 10 images in a particular folder. I am trying to do this in a single line command instead of creating a list. I was trying the following, but it errors out like below. Any suggestions?

echo `find ./folder1 -type f | grep .png | sort | tail -10 ;`| ffmpeg -f image2 -i - test.mp4

[image2 @ 0x21bf1c0] Could find no file with path 'pipe:' and index in the range 0-4
pipe:: No such file or directory
1
  • Wy do you think that -i - would take a list of files as input?
    – pLumo
    Commented Oct 6, 2021 at 7:25

1 Answer 1

2

ffmpeg expects image/video data, not a literal list of files unless you're using the concat demuxer. Adding cat will provide the data.

cat $(find . -maxdepth 1 -name '*.png' -print | sort | tail -10) | ffmpeg -framerate 25 -i - -vf format=yuv420p -movflags +faststart output.mp4

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .