This Go application generates video storyboards by extracting thumbnails from a given video file. It uses FFmpeg to create the thumbnails and assemble them into a storyboard image. The program also generates a VTT file for use with the storyboard, allowing each thumbnail to be linked with the corresponding time in the video.
- Extracts thumbnails from a video at a specified frame rate (FPS).
- Generates a storyboard image by arranging thumbnails in a grid.
- Creates a WebVTT file that links each thumbnail to its timestamp in the video.
- Cleans up temporary thumbnail files after the process is completed.
-
Clone the repository:
git clone https://github.com/yourusername/storyboard-generator.git cd storyboard-generator
-
Ensure Go and FFmpeg are properly installed on your system.
-
Build the Go executable:
go build -o storyboard
To use the program, run it with the following arguments:
./storyboard <fps> <input_file> <output_dir>
<fps>
: The frame rate (FPS) for extracting thumbnails from the video (e.g., 1 for one thumbnail per second).<input_file>
: The path to the video file (e.g.,example.mp4
).<output_dir>
: The directory where the storyboard image and VTT file will be saved (e.g.,./output
).
./storyboard 1 example.mp4 ./output
This will:
- Extract thumbnails from
example.mp4
at a rate of 1 frame per second. - Save the thumbnails and generated files in the
./output
directory. - Create a storyboard image named
storyboard.jpg
. - Create a VTT file named
storyboard.vtt
.
- storyboard.jpg: A single image file containing all the thumbnails arranged in a grid.
- storyboard.vtt: A WebVTT file that links each thumbnail to its timestamp in the video.
This project is licensed under the MIT License - see the LICENSE file for details.