python - OpenCV - Reading a 16 bit grayscale image -


i'm trying read 16 bit grayscale image using opencv 2.4 in python, seems loading 8 bit.

i'm doing:

im = cv2.imread(path,0) print im  [[25 25 28 ...,  0  0  0] [ 0  0  0 ...,  0  0  0] [ 0  0  0 ...,  0  0  0] ...,  

how 16 bit?

figured out. in case else runs problem:

im = cv2.imread(path,-1) 

setting flag 0, load grayscale seems default 8 bit. setting -1 loads image "as is".


Comments

Popular posts from this blog

django - How can I change user group without delete record -

java - Need to add SOAP security token -

java - EclipseLink JPA Object is not a known entity type -