how to get number of channels with PingImage
Posted: 2011-12-19T01:57:02-07:00
Hi everyone,
What's the recommended way to get the number of channels in an image with ping? I've been using GetImageType() after ReadImage() but this seem not to work for PingImage().
Here's what I see with IM 6.6.0 on Ubuntu 11.10 with a generic RGB jpg image.
PingImage(Gugg_coloured.jpg)
GetImageChannelDepth(DefaultChannels) = 1
GetImageChannelDepth(AllChannels) = 1
GetImageDepth() = 1
image->depth = 8
GetImageQuantumDepth(MagickFalse) = 8
GetImageType() = 1
IsGrayImage() = 1
IsMonochromeImage() = 1
IsOpaqueImage() = 1
ReadImage(Gugg_coloured.jpg):
GetImageChannelDepth(DefaultChannels) = 8
GetImageChannelDepth(AllChannels) = 8
GetImageDepth() = 8
image->depth = 8
GetImageQuantumDepth(MagickFalse) = 8
GetImageType() = 6
IsGrayImage() = 0
IsMonochromeImage() = 0
IsOpaqueImage() = 1
What's the recommended way to get the number of channels in an image with ping? I've been using GetImageType() after ReadImage() but this seem not to work for PingImage().
Here's what I see with IM 6.6.0 on Ubuntu 11.10 with a generic RGB jpg image.
PingImage(Gugg_coloured.jpg)
GetImageChannelDepth(DefaultChannels) = 1
GetImageChannelDepth(AllChannels) = 1
GetImageDepth() = 1
image->depth = 8
GetImageQuantumDepth(MagickFalse) = 8
GetImageType() = 1
IsGrayImage() = 1
IsMonochromeImage() = 1
IsOpaqueImage() = 1
ReadImage(Gugg_coloured.jpg):
GetImageChannelDepth(DefaultChannels) = 8
GetImageChannelDepth(AllChannels) = 8
GetImageDepth() = 8
image->depth = 8
GetImageQuantumDepth(MagickFalse) = 8
GetImageType() = 6
IsGrayImage() = 0
IsMonochromeImage() = 0
IsOpaqueImage() = 1