ffmpeg is a powerful utility for audio and video processing. However, you have to compile the source code yourself. This web page tells how to compile the source code of ffmpeg to become executables.
One very simple use of ffmpeg is to capture screen from a flv file. Actually, this is to save a video frame to file.
For example, this command :
will capture a frame from the file MyFile.flv at the time 00:00:31 to the file MyImage.jpg
ffmpeg -i MyFile.flv -ss 00:00:31 -vframes 1 -y MyImage.jpg
|
If you want to capture 101 frames, here is the command:
The will capture the 101 frames to the files MyImage-001.jpg to Myimage-101.jpg.
ffmpeg -i MyFile.flv -ss 00:00:31 -vframes 101 -y MyImage-%03d.jpg
|
However, under Windows, there is some special processing for the percent sign. Therefore, the command has to be adjusted as follow:
In short, double percent signs have to be used under Windows.
ffmpeg -i MyFile.flv -ss 00:00:31 -vframes 101 -y MyImage-%%03d.jpg
|
No comments:
Post a Comment