Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

How to get the bit-depth of an image?

Hi everyone, I have a PNG file which is 16bt per channel (total 48bit), but when I check the bit-depth with openCV using depth() it keeps returning CV_8U (zero).

int imgDepth = cvImage.depth();

Can someone please provide me with a solution to this problem, or at least explain what I'm doing wrong?

Thanks in advance, Mark.