morphology python sample

This commit is contained in:
Alexander Mordvintsev
2011-07-01 08:22:45 +00:00
parent ad454d83b9
commit 382e154cfd
2 changed files with 54 additions and 12 deletions

View File

@@ -54,3 +54,6 @@ def mtx2rvec(R):
axis = np.cross(vt[0], vt[1])
return axis * np.arctan2(s, c)
def draw_str(dst, (x, y), s):
cv2.putText(dst, s, (x+1, y+1), cv2.FONT_HERSHEY_PLAIN, 1.0, (0, 0, 0), thickness = 2, linetype=cv2.CV_AA)
cv2.putText(dst, s, (x, y), cv2.FONT_HERSHEY_PLAIN, 1.0, (255, 255, 255), linetype=cv2.CV_AA)