Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Draw a Line | Fundamentals of Image Manipulation with Python
Fundamentals of Image Manipulation with Python
course content

Conteúdo do Curso

Fundamentals of Image Manipulation with Python

bookDraw a Line

In OpenCV, the cv2.line() function is used to draw a line on an image. The function takes five required parameters:

  • the image to be modified;
  • the starting point of the line (specified as a tuple of x and y coordinates);
  • the ending point of the line (specified as a tuple of x and y coordinates);
  • the color of the line (specified as a tuple of Red, Green, Blue values);
  • the thickness of the line.
Tarefa
test

Swipe to show code editor

  1. Use the correct function to draw a line on image1.

Mark tasks as Completed
Switch to desktopMude para o desktop para praticar no mundo realContinue de onde você está usando uma das opções abaixo
Tudo estava claro?

Como podemos melhorá-lo?

Obrigado pelo seu feedback!

In OpenCV, the cv2.line() function is used to draw a line on an image. The function takes five required parameters:

  • the image to be modified;
  • the starting point of the line (specified as a tuple of x and y coordinates);
  • the ending point of the line (specified as a tuple of x and y coordinates);
  • the color of the line (specified as a tuple of Red, Green, Blue values);
  • the thickness of the line.
Tarefa
test

Swipe to show code editor

  1. Use the correct function to draw a line on image1.

Mark tasks as Completed
Switch to desktopMude para o desktop para praticar no mundo realContinue de onde você está usando uma das opções abaixo
Seção 1. Capítulo 10
AVAILABLE TO ULTIMATE ONLY
We're sorry to hear that something went wrong. What happened?
some-alt