Drawing on TIFF with Alpha Channel enabled

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
mackermedia
Posts: 15
Joined: 2013-01-25T12:59:01-07:00
Authentication code: 6789

Drawing on TIFF with Alpha Channel enabled

Post by mackermedia »

I am working to use mogrify to modify a source template image to do a number of different operations: add background color, add text, add image, etc.

I have the operations working successfully when I start with a source tif that is all white and has no Alpha Channel enabled.

I now want to be able to start with a fully transparent source template file, apply any of the operations, and save a new image with transparency.
The problem is, now that I'm starting with a fully transparent image, none of the same operations are affecting the image. The output is always the same fully transparent image.

Do I need to do some conversion of the source file before attempting modifications? Should I be starting with a different source template file and converting to TIFF at the end?

Any help will be greatly appreciated.
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Drawing on TIFF with Alpha Channel enabled

Post by snibgo »

Why are you using "mogrify" to change a single image? "convert" might be a better choice.

Tiff files work fine for me, transparent or otherwise.

For more specific help, you might mention your platform, version of IM, and exact commands you are trying.
snibgo's IM pages: im.snibgo.com
mackermedia
Posts: 15
Joined: 2013-01-25T12:59:01-07:00
Authentication code: 6789

Re: Drawing on TIFF with Alpha Channel enabled

Post by mackermedia »

Thanks for your reply.

I'm using mogrify, because I'm using mini_magick (a ruby wrapper on image magicks mogrify command).

I was simply attempting a -draw command with -fill specified to set a background color as a test. This is failing when starting with a fully transparent .tif.

Turns out, simply starting with a fully transparent .png image and applying the operations, then saving as .tif works like a charm.
Post Reply