Created
June 7, 2012 18:29
-
-
Save FSX/2890634 to your computer and use it in GitHub Desktop.
Make a set of thumbnails of a video.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
filename=$(basename $1) | |
# Uncomment for fancy notifications | |
# notify-send "$filename" "Created thumbnail overview..." --icon=emblem-videos-symbolic | |
Streams=$(ffmpeg -i $1 2>&1 | grep '^[[:blank:]]*Stream' | sed 's/^[^:]*.[^:]*..//;s/([^)]*.//g;s/ ,/,/g') | |
Text=$(echo "File: $filename\nSize: $(ls -lah $1 | awk '{ print $5}')\n$Streams") | |
# http://code.google.com/p/ffpoth/ | |
# Seems to be dead; needs replacement | |
ffpoth -b1 -e-1 -n32 -w 200 "$1" | montage - -geometry +1+1 -tile 4x MIFF:- | convert label:"$Text" - -append "${filename%.*}-overview.png" & |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment