ffMpeg batch example

How to create a gif file from several images by using ffmpeg?

Create a new text file and save it with the extension “.bat”. Then copy the following code, change the settings accordingly.

@ECHO OFF
SET FFMPEG="c:\Program Files (x86)\ffmpeg\bin\ffmpeg.exe"
SET SOURCE="d:\Temp\png\Dia%%d.PNG"
SET TARGET="d:\Temp\png\output.gif"
ECHO Convert source folder with images to gif
%FFMPEG% -f image2 -framerate 0.2 -i %SOURCE% %TARGET%
PAUSE

How to grab images from a movie by using ffmpeg?

Create a new text file and save it with the  extension “.bat”. Then copy the following code, change the settings accordingly.

SET MOVIE=”MovieName.mp4″
SET OUTPATH=”c:\Temp\Output\”
ECHO 1. Start converting video to audio, later used to extract transcript
%FFMPEG% -i %MOVIE% -map 0:1 -acodec pcm_s16le -ac 2 %MOVIE%.wav
ECHO 2. Convert video to images
%FFMPEG% -i %MOVIE% -vf fps=1/60 jpgIMG_%%05d.jpg/
PAUSE

FFmpeg References