FFMPEG for animation of image files outputs all-black video
Solution 1:
The videos generated with your files and the following commands both play fine for me in ffplay
. The one with yuv420p
chosen as the pixel format also plays fine in QuickTime.
ffmpeg -r 1 -i f_%02d.png out.mp4
ffmpeg -r 1 -i f_%02d.png -pix_fmt yuv420p out.mp4
Only VLC has troubles displaying the video (download). It'll show me a second of grey and then black, but not for a duration of 8 seconds.*
To produce stable video, you can try to increase the output frame rate, since it's the 1 fps that most players will choke on. The output file will be bigger than needed, of course.
ffmpeg -r 1 -i f_%02d.png -r 25 out.mp4
ffmpeg -r 1 -i f_%02d.png -pix_fmt yuv420p -r 25 out.mp4 <= for older players
Here we've told to read the images at 1 frame per second, but output them (duplicating frames) at 25.
* I consider this a bug with VLC. Since it's based on libavcodec and libavformat (from the FFmpeg project), and ffplay
handles the file just fine, VLC should have no major issues with it. I would suggest you create a bug report in VLC – chances are the file isn't parsed correctly.