Cv2 rectangle different color. rectangle() method is used to draw a rectangle on an image.