HSV values of a pixel in OpenCV

asked 2019-03-09 17:11:35 -0600

I am having trouble in interpreting HSV values processed in OprnCV. I have an image that I convert to HSV :
img = cv2.cvtColor(img,cv2.COLOR_BGR2HSV)

I have a pixel that Gimp says it is [345 95 72] but when I print the value of same pixel it is [160 5 150] . I had the impression that Gimp and Open CV have a relationship like: OpenCV HSV = GIMP[H/2, (S255)/100, (V255)/100]

Is my understanding correct ? Does after conversion (cv2.cvtColor), the value of matrix points are HSV ?

Thanks, Alok

edit retag flag offensive close merge delete

Comments

read hsv doc

LBerger gravatar imageLBerger ( 2019-03-10 04:02:22 -0600 )edit