Page 1 of 1

Transparent PNG to transparent TIFF

Posted: 2009-10-12T10:09:27-07:00
by axelrose
Hello,

I test some transparency option and look for optimizations.

If I use this PNG with alpha channel:

Image

and convert to TIFF with

Code: Select all

convert transp.png transp.tif
I'll get this result:

Image

which looks fine at first glance. When looking very carefully you could see some tiny
differences between the alpha channel of both images.

A minor annoyance is if I open in Photoshop CS4 the background is black rather
than transparent, see:

Image

How could I improve this?


Many thanks
Axel

IM is version 6.5.4-7

Re: Transparent PNG to transparent TIFF

Posted: 2009-10-12T10:40:35-07:00
by fmw42
I don't really see any differences between your two image.

I took your image and tried the same thing of converting to tif and displaying in PS CS8 and got the same result. It looks like PS does not recognize the transparency in TIFs. It works fine with your PNG. I also made a totally transparent tif and it was black. IM transparency is rgb=black and transparency=0. So if PS is ignoring the transparency, you will see just black or whatever is in your rgb channels.

I don't know if there is a bug in IM or not.

In PS, you have to check a special box to save transparency and it warns that many programs do not recognize transparent tifs. But I was able to save it and display it again with transparency in Mac PREVIEW and PS. So perhaps PS has a special way of saving transparency. Or perhaps IM is not setting that flag in the Tif file correctly.

I will leave the rest to the IM folks to comment or verify.

Re: Transparent PNG to transparent TIFF

Posted: 2009-10-12T12:20:30-07:00
by magick
ImgeMagick produces proper PNG and TIFF transparent images that follow the published standards. Adobe most likely expects transparent images to have certain characteristics otherwise it ignores the transparency channel. If you let us know what Adobe requires, we will let you know how to use the command line to produce an image that Adobe can process.