Hi,
I've been searching about this thing and couldn't find it. How to get the transparent color of an image? my purpose is creating another image (not duplicating) which has the same transparent color. Another purpose is to check whether an image has transparency or not.
So...is there any method to do that?
Thanks.
Getting transparent color?
- anthony
- Posts: 8883
- Joined: 2004-05-31T19:27:03-07:00
- Authentication code: 8675308
- Location: Brisbane, Australia
Re: Getting transparent color?
All I know is the transparent color is saved as image meta-data attribute, for later use if the -transparnet-color setting is not defined.
Internally how this is done' I have not looked, but following the command line API is not too difficult.
Use the source Luke!
Internally how this is done' I have not looked, but following the command line API is not too difficult.
Use the source Luke!
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
https://imagemagick.org/Usage/
Re: Getting transparent color?
thanks for the info, although I still didn't get it how to return the image's transparent color, I just compare with imagecolortransparent from GD.
Re: Getting transparent color?
Well, you can easily get the info from the return string from MagickDescribeImage(), just look at the output and it should be fairly straightforward to get the transparent color attribute from it.
FR: MagickDescribeImageArray() ?
/tsr
FR: MagickDescribeImageArray() ?
/tsr