颜色变换cvtColor
1 | import cv2 |
画基本图形
画矩形
1 | def rectangle(img, pt1, pt2, color, thickness=None, lineType=None, shift=None): |
1 | import cv2 |
画圆
1 | def circle(img, center, radius, color, thickness=None, lineType=None, shift=None): |
1 | import cv2 |
画椭圆
1 | def ellipse(img, center, axes, angle, startAngle, endAngle, color, thickness=None, lineType=None, shift=None): |
1 | import cv2 |
画线段
1 | def line(img, pt1, pt2, color, thickness=None, lineType=None, shift=None): |
1 | import cv2 |
画多边形
1 | def polylines(img, pts, isClosed, color, thickness=None, lineType=None, shift=None): |
1 | import cv2 |
填充多边形
1 | def fillPoly(img, pts, color, lineType=None, shift=None, offset=None): |
1 | import cv2 |