opencv - What are Python constants for cv2.solvePnP method flag? -
i need use cv_p3p solvepnp method, there doesn't seem documentation of python equivalents of c++ flags, cv_iterative, cv_p3p , cv_epnp. i've tried cv2.cv_p3p, cv2.p3p, cv2.cv.p3p, etc.
i've found few questions asking this, including these:
http://opencv-users.1802565.n2.nabble.com/solvepnp-name-of-flag-constants-in-python-td7484093.html
http://answers.opencv.org/question/8861/what-opencv-constants-are-available/
but no answers, apart link source page, defines python constants. there seem no references constants i'm looking for. https://github.com/itseez/opencv/blob/e3ae36dcb3c1d523802f8642e5c3984db43637c4/modules/python/src2/defs
i tried passing integers argument, still seems using default method.
is possible other solve methods don't exist in python version of opencv?
i found following constants worked:
cv2.solvepnp_iterative
cv2.solvepnp_p3p
cv2.solvepnp_epnp
cv2.solvepnp_dls
e.g:
retval, orvec, otvec = cv2.solvepnp(object_points, image_points, camera_matrix, none, none, none, false, cv2.solvepnp_iterative)
Comments
Post a Comment