Ask Your Question

Revision history [back]

How does opencv convert floating points data to uint8 in imwrite function to save as .jpg?

There is a 3 dimensional image array that contain floating points. I could save it with opencv-python as cv2.imwrite('.jpg',image_array). If I load the saved image with opencv, It produce output with uint8 and it is not the same with the type cast (uint8) value to the original float array.