Extract one frame per second as images
gif & images
// what it does
Samples the video at one frame per second and writes them as zero-padded PNGs (frame_0001.png, frame_0002.png, ...). The fps=1 filter resamples the timeline, duplicating or dropping source frames to hit the target rate rather than seeking to exact second marks. Useful for building preview strips, sampling frames for an ML dataset, or eyeballing scene changes.
// shell
$ ffmpeg -i input.mp4 -vf fps=1 frame_%04d.png// gotcha
fps=1 is a resampling filter, not a precise seek — the emitted frames are the nearest available frames to each 1-second slot, so they don't align to exact timestamps. The image2 muxer also overwrites any existing frame_*.png files without prompting.