Apply text to a canvas within a bounding box at max size?
Posted: 2012-10-03T06:27:29-07:00
Hello,
I've become quite fond of ImageMagick through PHP's "Imagick" interface/wrapper. However, my shared hosting account where I'll be generating some fun dynamic email headers does not support it. It DOES support direct "convert" command line calls (who would have thought?). Could I trouble someone to help me get to know ImageMagick commands better through this mini-project?
Here's my final goal, a header that calls out invitees to an education benefit party by name:
using this fun starting canvas:
and the freely available Comic Book font by Neale Davidson.\
The challenge is sizing the name so that any length will fit:
I could do this with PHP's help if an ImageMagick command could return the text dimensions at a set size, or if there is a "best fit" option that I could use within a restricted bounding box over the base image canvas.
Any tips you could provide would be awesome, and even help me help the Space Foundation make STEM (science technology engineering math) education programs for kids, AWESOME!
Thanks in advance,
Chris
Shameless promotion: You should go and "like" or share this page: http://www.scifisprings.com
I've become quite fond of ImageMagick through PHP's "Imagick" interface/wrapper. However, my shared hosting account where I'll be generating some fun dynamic email headers does not support it. It DOES support direct "convert" command line calls (who would have thought?). Could I trouble someone to help me get to know ImageMagick commands better through this mini-project?
Here's my final goal, a header that calls out invitees to an education benefit party by name:
using this fun starting canvas:
and the freely available Comic Book font by Neale Davidson.\
The challenge is sizing the name so that any length will fit:
I could do this with PHP's help if an ImageMagick command could return the text dimensions at a set size, or if there is a "best fit" option that I could use within a restricted bounding box over the base image canvas.
Any tips you could provide would be awesome, and even help me help the Space Foundation make STEM (science technology engineering math) education programs for kids, AWESOME!
Thanks in advance,
Chris
Shameless promotion: You should go and "like" or share this page: http://www.scifisprings.com