Generate images overlayed by random text, automation

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
Uwec
Posts: 1
Joined: 2013-02-22T18:42:30-07:00
Authentication code: 6789

Generate images overlayed by random text, automation

Post by Uwec »

Hello guys,

I"m looking for some easy ready-to-use solution for the following process:
(Please advice me if Imagemagic can do it):

- take a random pick of any size from the given folder
- take a random piece of text from the chosen .txt
- overlay text on the picture
- save the result to the chosen folder
+ repeat the above сycle N times with one and the same set to mix combinations in different ways

If it's impossible to do by ImageMagic, than maybe someone here has a script like I describe or knows where it can be lookes for?

Thank you!
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Generate images overlayed by random text, automation

Post by snibgo »

ImageMagick can overlay text on a picture.

A script could choose the random picture and random text.
snibgo's IM pages: im.snibgo.com
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: Generate images overlayed by random text, automation

Post by anthony »

IM can also automatically size the text to a given area.
http://www.imagemagick.org/Usage/text/#label_bestfit
http://www.imagemagick.org/Usage/text/#caption_bestfit
Though rotations, and other effects need to be added seperatally.

All you really need do is put it all together in a script.
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
Post Reply