On 2026-08-31 10:46 pm, William C Bonner via ffmpeg-user wrote:
On Sun, Aug 30, 2026 at 2:44 AM Olivier Sannier via ffmpeg-user <
[email protected]> wrote:

Hello,

I have a collection of jpeg files like so:

output_2026-08-28_10-24-23.jpg
output_2026-08-28_10-24-33.jpg
output_2026-08-28_10-25-06.jpg
output_2026-08-28_10-53-54.jpg
output_2026-08-28_10-54-32.jpg
output_2026-08-28_11-06-46.jpg

This is a test set of files, in the future they will all be spaced by
the same amount of time, but for my initial testing, this will do.

The goal is to create a timelapse where each image has the same duration
and after reading around, I came up with this command line:

ffmpeg -r 1 -pattern_type glob -i './images/output_*.jpg' -c:v libx264
-y timelapse.mp4

This does not output an error, however, using VLC Player to read the
generated file, I have noticed a few strange things:

* With one or two images, nothing is played
* With three or four images, only the first two frames are played before
VLC stops
* With five images, only the first three frames are played before VLC stops
* With all six images, only the first 4 frames are played and VLC stops

I tried replacing libx264 with mpeg2video or mpeg4 but the results were
worse, the generated video is not even readable by VLC.
I tried adding -pix_fmt yuv420p -s 1920x1080 before -c:v which
effectively changed the video resolution but did not change the x264
result when reading it. It allowed to get a working mpeg video file, but
with the same "only 4 frames used" result
I tried replacing -r 1 with -framerate 1 but this did not change the result
I tried replacing -c:v with  -vcodec libx264 -acodec aac  but that too
did not change the result

I'm sure that I did something wrong here, but I can't figure out what
just yet. I have placed a debug log of the above original command at the
end of this email.

Thanks a lot for your help.

Olivier


You might want to try using a simpler codec such as mjpeg to see if you get
the results you want.

Not codec related. VLC has issues playing very low framerate videos.

Ingest the frames at a low rate but produce a higher FPS video, like this:

  ffmpeg -framerate 1 -pattern_type glob -i './images/output_*.jpg' -r 15 -c:v 
libx264
-y timelapse.mp4


Regards,
Gyan

_______________________________________________
ffmpeg-user mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to