GetAttribute shows type as 'Palette' but identify shows as 'Bilevel.
Posted: 2018-06-18T13:38:52-07:00
I have a script that works based on image type.
Then I have a couple if statements:
and an else to print out the file and image type if it doesn't match any of those three. However, I am getting errors in my logs for files because they are of type 'Palette'. When I use identify on the image the type is 'Bilevel'. I did not see 'Palette' anywhere in the identify output. I'm not sure what is going on. I am using ImageMagick 7.0.7-28 q16. Any ideas?
Code: Select all
my $imageType = $image->GetAttribute('type');
Code: Select all
if($imageType eq 'Bilevel')
if($imageType eq 'Grayscale')
if($imageType eq 'TrueColor')