User Tools

Site Tools


ffmpeg:video:frame:extract_frames

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

ffmpeg:video:frame:extract_frames [2025/01/29 22:51] – created peterffmpeg:video:frame:extract_frames [2025/01/29 23:03] (current) peter
Line 1: Line 1:
 ====== ffmpeg - Video - Frame - Extract Frames ====== ====== ffmpeg - Video - Frame - Extract Frames ======
 +
 +===== Extract a single frame =====
 +
 +<code bash>
 +ffmpeg -i input.mp4 %02d_out.jpg -frames:v 1
 +</code>
 +
 +<WRAP info>
 +**NOTE:** Write a single image.
 +
 +</WRAP>
 +
 +----
 +
 +===== Extract a sequence of frames =====
 +
 +<code bash>
 +ffmpeg -i input.mp4 %02d_out.jpg
 +</code>
 +
 +<WRAP info>
 +**NOTE:** The output needs to be an image sequence pattern.
 +
 +  * **%02d**:  This is a pattern for an image sequence or use the -update option (with -frames:v 1 if needed) to write a single image.
 +
 +</WRAP>
 +
 +----
 +
 +===== Extract resized =====
 +
 +<code bash>
 +ffmpeg -i $(video_in) -vf scale=-1:$(resize_width),fps=$(FPS) $(path)/$(name)_%02d_out.jpg
 +</code>
 +
 +----
 +
  
ffmpeg/video/frame/extract_frames.1738191072.txt.gz · Last modified: 2025/01/29 22:51 by peter

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki