FORUMS: list search recent posts

Batch process videos to thumbs (preserve filename, add actual time-stamp)

COW Forums : FFmpeg

<< PREVIOUS   •   VIEW ALL   •   PRINT
Lopici Gaspar
Batch process videos to thumbs (preserve filename, add actual time-stamp)
on Oct 8, 2017 at 8:25:03 pm
Last Edited By Lopici Gaspar on Oct 8, 2017 at 8:28:22 pm

Using ffmpeg, I am writing a script to create thumbnails, at every 5 sec, from 100s of videos of different filetypes (.mp4, .mts, .avi, .wmv), all videos being in one folder. I am having trouble to figure out how to handle the thumbnail filenames, so (i) it preserves the video's filename (without extension), yet (ii) appends with a __timestamp corresponding with the actual seconds of the thumbnails taken (e.g., __0005, __0010, __0015... up to __5400, in case of a 90 min video).

ffmpeg is installed: C:\ffmpeg
source videos' dir: C:\video
thumbnails to be placed: C:\thumb


intended thumbnail filename output (e.g., from 2 videos):

video-1__0005.png or jpg
video-1__0010.png
video-1__0015.png
video-2__0005.png or jpg
video-2__0010.png
video-2__0015.png
video-2__0020.png
video-2__0025.png


current script:

C:\video>ffmpeg -i video-1.mp4 -vf fps=0.2 C:\thumb\__%04d.png

What I am missing to have the intended filename output? (Either Command line or PowerShell solutions would be helpful.) Thank you!


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT
© 2017 CreativeCOW.net All Rights Reserved
[TOP]