Skip to main content

Command Palette

Search for a command to run...

Computer Vision: Geometric shapes on Image.

Published
1 min read

Now, we are taking images and drawing the geometric shapes on the image. Here we take the Lena image and draw a line on it. command is cv2.line()

Steps:

  • First, we need to take an image

  • Take the cv2.line in that gives the image

  • first give starting point 0,0

  • Then ending point (255,255)

  • The thickness of the line is equals to 5.

Now, we are taking the same Lena image and then drawing the arrow on it. The command is arrowedLine and gives an image on it.

Drawing rectangle on the lena image.

Drawing a circle on the image.

We are putting the text on the image

Thanks for reading,

Mohammed Muqafamuddin.