Lets say you have some drone footage, or you want to extract frames from videos for pumping into a photogrammetry software to make a 3D model.

This process is a bit clunky, but does the job nicely using a Windows Batch file.

  1. Go HERE and follow the 15 steps to install FFmpeg.
    1. If you don’t want to go there, then do the following
      1. Download FFmpeg supported by GYAN https://www.gyan.dev/ffmpeg/builds/ffmpeg-git-full.7z.
      2. Extract and put into your C Drive for easy access.
      3. Rename the folder to FFmpeg. (See image below)
      4. Create an environment variable for the Path and point it to C:/FFmpeg/bin <- the bin folder. (See image below)
      5. Done
  2. Create a Batch file with the following code.
    for %%F in (*.mp4) do (
    If not Exist "%%~nF" MkDir "%%~nF"
    ffmpeg -i %%F -r 1 -qscale:v 2 %%~nF\%%~nF-%%3d.jpg
    )
  3. Place the bat file in the folder with the clip/clips of footage and run it. This will extract the frames (1 frame per second of footage) to a folder with the same name as the mp4 clip.

Then you have the frames and you can push to Polycam, or Zephyr, or any other photogrammetry software.

If you want to get more frames out of the clip, the code ‘-r 1’ tells ffmpeg to export 1 frame a second. Up this to 2 for 2 frames a second.

We use 3D Flow as it allows the extraction of frames of footage and takes into account the blurryness of the frame. FFmpeg does not do this so be wary.

Good Luck