https://github.com/codebox/video-barcode-generator
Video Barcode Generator
https://github.com/codebox/video-barcode-generator
Last synced: 27 days ago
JSON representation
Video Barcode Generator
- Host: GitHub
- URL: https://github.com/codebox/video-barcode-generator
- Owner: codebox
- License: mit
- Created: 2011-08-09T12:15:47.000Z (over 14 years ago)
- Default Branch: master
- Last Pushed: 2019-03-06T08:36:39.000Z (about 7 years ago)
- Last Synced: 2025-06-12T12:13:38.531Z (10 months ago)
- Language: Shell
- Homepage: http://codebox.org.uk/pages/scripts/video-barcodes
- Size: 3.91 KB
- Stars: 6
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Video Barcode Generator
This shell script extracts still frames from video files, and uses them to generate Video Barcode images like these:
### Star Wars
[](/assets/images/video-barcodes-script/star-wars-video-barcode.jpg "Star Wars Video Barcode")
### The Empire Strikes Back
[](/assets/images/video-barcodes-script/empire-strikes-back-video-barcode.jpg "Empire Strikes Back Video Barcode")
### Return of the Jedi
[](/assets/images/video-barcodes-script/return-of-the-jedi-video-barcode.jpg "Return of the Jedi Video Barcode")
The script should work on Linux and Mac OSX, and has dependencies on [ffmpeg](http://www.ffmpeg.org) and [ImageMagick](http://www.imagemagick.org). It is based on an idea by [Benoit Romito](http://bromito.perso.info.unicaen.fr/wiki/index.php) but uses a different technique to create the images, explained [below](#explained).
### How it works
The script requires a single command-line argument, which should be the location of the video file for which the barcode is to be generated, for example:
makebarcode.sh starwars.avi
The script extracts still frames from the video at one-second intervals, and saves them as JPEG image files (to change the interval between stills, and therefore the length of the barcode, adjust the STEP variable). Each image is then squashed to be only 1 pixel wide, and 400 pixels high, and these squashed images are stitched together horizontally to form a barcode.