Add transparent PNG to T-Shirt

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
midget2000x
Posts: 2
Joined: 2016-04-26T10:26:22-07:00
Authentication code: 1151

Add transparent PNG to T-Shirt

Post by midget2000x »

I'm a noob to this board, but I have used ImageMagick a bit in the past for simpler projects. I'm wondering if ImageMagick could help me do this either in a batched method (with a script) or perhaps even in real-time using an API program.

I have images of blank t-shirts in many different colors - all a uniform size (1000x1000).

I also have alot of transparent PNGs of art (example: "BEER & BOWLING" on a 50s style sign).

Previously, we've been applying the art to the blanks manually but I'm thinking there has to be an automated, or semi-automated way to overlay the transparent PNG onto the blank shirt with ImageMagick.

I realize there are alot of variables, like the size and orientation of the PNG, dimensions of the printable space on the shirt itself, etc...stuff that is easier to deal with when you have a person "eyeing" each application. So I imagine there will need to be a formula developed.

Given all this, has anyone done anything like this?

I'm thinking that since there are only a handful of shirts (20 or so), I could create blanks that have the printable art area demarcated with a box either in a separate layer, a separate image or as a stroke on the image itself. Then ImageMagick would perhaps "know" the dimensions of the area in which to place the art, and then the process could discard or hide the box for the final combined version.

Just seeing if something like this is possible, or perhaps someone has a different idea on how to execute?
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Add transparent PNG to T-Shirt

Post by fmw42 »

If you are on Unix (Linux, Max OSX or Windows with Cygwin), see my scripts, tshirt and tshirtwarp at the link below.

Please always provide your IM version and platform when asking questions on this forum, since syntax may differ.
midget2000x
Posts: 2
Joined: 2016-04-26T10:26:22-07:00
Authentication code: 1151

Re: Add transparent PNG to T-Shirt

Post by midget2000x »

woah! - fred this is awesome. thanks so much!
Post Reply