Created
May 16, 2016 21:17
-
-
Save ibaaj/7b0699e5e14bcef5685b7189e738c2ef to your computer and use it in GitHub Desktop.
TextBuilding.sh
This file contains 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 | |
W=`identify ./img.jpg | cut -f 3 -d " " | sed s/x.*//` #width | |
H=`identify ./img.jpg | cut -f 3 -d " " | sed s/.*x//` #height | |
convert -size ${W}x${H} xc:black -fill white -stroke black -draw "path 'M +780+1000 +2075+1054 +2431+3115 +80+2865" mask.png | |
convert img.jpg mask.png -alpha off -compose CopyOpacity -composite final.png | |
convert final.png -fuzz 45% -transparent white text.png | |
x="convert img.jpg " #" tttt.png -composite " | |
for i in `seq 0 5 500` | |
do | |
x="$x text.png -geometry +0-${i} -composite " | |
done | |
x="$x EXITSUCCESS.png" | |
echo $x | |
eval $x |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment