imshow & 图像深度

https://blog.csdn.net/qq_39642978/article/details/95926315

https://www.cnblogs.com/Xiaoyan-Li/p/5674792.html

图像深度对应值:

#define CV_8U 0
#define CV_8S 1
#define CV_16U 2
#define CV_16S 3
#define CV_32S 4
#define CV_32F 5
#define CV_64F 6
#define CV_USRTYPE1 7

查看方式: img.depth()

像素归一化

8-bit unsigned: 显示图像本来的样子;
16-bit unsigned / 32-bit integer: 用像素值除以256,取值范围由[0,255x256]变为[0,255];
32-bit floating-point: 像素值乘以255, 取值范围由[0,1]变为[0,255]。

原文地址:https://www.cnblogs.com/wllwqdeai/p/11757370.html