How can i get screenshot like this using ffmpeg command line? i found to extract only one frame but i could not find any command line to create screenshot like this using ffmpeg.
https://forum.videohelp.com/images/imgfiles/xGcbp4F.jpg
currently i using mtn file. i got an output like this https://forum.videohelp.com/images/imgfiles/Z9fxzWV.jpg
it's like mtn movie thumbnailer could not read the middle of the video file time line. it happened for couple of video file. i tried few other command line for mtn movie thumbnailer but result is same. so i want to test with FFMPEG.
+ Reply to Thread
Results 1 to 9 of 9
-
-
Something like:
Code:ffmpeg -i %1 -vf "select='eq(pict_type,I)',scale=192:-2,tile=2x4" -vsync 0 "%1_preview_I_frame_%%06d.png"
Last edited by pandy; 26th Jul 2021 at 15:49.
-
thank you, it's working fine.
it seems ffmpeg or mtn having trouble to read files for that particular files. anyway for ffmpeg i used `--ss 00:05:00` and tried the `tile=2x4` mode. ffmpeg made the screenshot but it made all screenshot close to 5 min duration. default settings take random frame screenshot. is there anyway i can set from which duration ffmpeg will start to take screenshot and add the time interval as well? like start to take screenshot from --ss 00:05:00 and give 2min interval to take next images? -
Use the seconds formula:
Code:ffmpeg -i input -filter_complex "select='not(mod(n,120))',scale=120:-1,tile=layout=3x2:padding=4" -vframes 1 -q:v 2 output.jpg
Scale each frame to a smaller size (alternatively you can scale after tile)
Tile each frame into one image. Default grid size is 3x2, Padding between images is 4 pixels
You may have to adjust that with layout depending on how many images you want to display.
[Attachment 60080 - Click to enlarge]Last edited by Budman1; 27th Jul 2021 at 23:01.
-
i am not sure but is't `scale=xx` using for the the image wide?
may be use this?
-vf fps=1/100
Code:https://trac.ffmpeg.org/wiki/Create%20a%20thumbnail%20image%20every%20X%20seconds%20of%20the%20video
-
may be use this?
-vf fps=1/100
The scale=120:-1 says scale the width to 120 pixels and the height proportional to the oruiginal aspect (-1)
select='not(mod(n,120)) means select 1 frame every 120 seconds (2 minutes)
padding=4 means separate each image by 4 pixels. So:
3x120 =360 plus 2 gaps of 4=8 total is 368 pxels, as shown by the screen ruler -
thank you so much, i mixed up with scale and "select='not(mod(n,120))". my bad.
i added -ss 00:10:00 and then i added select='not(mod(n,200)). i got the desire output screenshot.
Similar Threads
-
Create background sound for video with ffmpeg
By qo4on in forum EditingReplies: 3Last Post: 26th Nov 2020, 12:50 -
ffmpeg - create video from scrolling image
By M00nsp3ll in forum Newbie / General discussionsReplies: 0Last Post: 7th Apr 2020, 15:27 -
Create a Few Seconds Video preview Using Ffmpeg
By dexterfox44 in forum Newbie / General discussionsReplies: 1Last Post: 28th Feb 2020, 06:49 -
How do I use ffmpeg to create the highest quality animated gifs from video
By Bruce Banner in forum EditingReplies: 13Last Post: 11th May 2019, 00:26 -
No thumbnail or properties after rotating portrait video with ffmpeg
By capncodfish in forum Newbie / General discussionsReplies: 2Last Post: 11th Dec 2016, 21:09