[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: adding text to JPEGs, in bulk



I had to do that just the other day - here's what I used:
ls *.jpg | xargs -l -i convert -resize "50%" -gravity Center
-pointsize 48 -fill "#fff" -draw 'text 0,0 "{}"' -fill "#000" -draw
'text 5,5 "{}"' {}  thumbs/{}

You may need to tweak the size, pointsize, color, etc.  I also had to
put "arial.ttf" in the path where imagemagick was looking for it.
(/usr/share/fonts/default/TrueType/)

"thumbs" is the directory I chose to output to (had to mkdir first).

Using xargs helps when you're dealing with thousands of files...

HTH,
Chris


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]