我不知道,为什么这个openCV函数给了我None的值,有什么想法?
while True:
retval,frame = capture.read()
h, w = frame.shape[:2]
gray = cv2.cvtColor(frame, cv2.cv.CV_BGR2GRAY)
found, points = cv2.findChessboardCorners(gray, p_size)
if found!=0:
frame_count = frame_count + 1
objpoints.append(objp)
corners2 = cv2.cornerSubPix(gray, points, (11, 11), (-1,1), criteria)
imgpoints.append(corners2) </i>
答案 0 :(得分:7)
如果您查看关于cv2.cornerSubPix
的{{3}},则可以看到它返回“无”。实际上它会修改作为参数传递的角点数组。
cv2.cornerSubPix(image, corners, winSize, zeroZone, criteria) → None