Page 1 of 1

colordepth of the whole image not the separate channels?

Posted: 2017-10-11T04:05:58-07:00
by tco95ttocs
Hi guys,

is there a possibility to get the colordepth of an image?
For example i have a 4 channel tif-file and each channel has 8bit.
So is there a function which gives me 32 as the colordepth of the image?

thanks

Re: colordepth of the whole image not the separate channels?

Posted: 2017-10-11T05:32:01-07:00
by snibgo
I don't use Magick.NET, but I don't think there is a function for that. You can write your own, that multiplies the number of channels by the bits per channel.

Re: colordepth of the whole image not the separate channels?

Posted: 2017-10-11T22:12:08-07:00
by dlemstra
There is no function for that but you could do `image.Depth * image.ChannelCount` as @snibgo suggested.

Re: colordepth of the whole image not the separate channels?

Posted: 2017-10-11T23:36:28-07:00
by tco95ttocs
thx for the fast answer