Convert changes image type from Bilevel to Grayscale

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
vi.srikanth
Posts: 3
Joined: 2011-04-22T00:54:39-07:00
Authentication code: 8675308

Convert changes image type from Bilevel to Grayscale

Post by vi.srikanth »

Hi

I have a tif, and I tried converting it to PNG in Linux and in Windows. Its original image type is "Bilevel". When I convert it to PNG in Windows, the PNG has "Grayscale" as its image type, however in Linux I still end up with a "BiLevel" as image type! Why is this change in behavior between Linux and Windows? My guess is that it is do with imagemagick configuration XMLs. Or is it something else? Could you please help me on how to configure/change/control this behavior?

Thanks
Srikanth
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: Convert changes image type from Bilevel to Grayscale

Post by fmw42 »

What is your command? what do you want it to be bilevel or grayscale? Can you post a link to your tiff image?
User avatar
glennrp
Posts: 1147
Joined: 2006-04-01T08:16:32-07:00
Location: Maryland 39.26.30N 76.16.01W

Re: Convert changes image type from Bilevel to Grayscale

Post by glennrp »

The PNG format does not have a "bilevel" subtype. If you convert an image that has only black or white pixels, it will be converted to a grayscale PNG with bit_depth == 1, which is essentially the same thing.
Post Reply