Which pixels are included along a contour line when using cv2.drawContours

asked 2020-02-24 07:24:35 -0600

Hi all, I'm new to OpenCV and so far have few critical open questions with no answer. When I draw a filled polygon that I use as a mask, how do I know which of the pixels along the contour are included or not within this polygon? are all the pixels along the contour line are included or just those in the inner side? What about a diagonal line, how then it is determined? and if I want the outer pixels nearby the contour lines?

I will appreciate any help regarding those questions and even general information about how can I control/determine the pixels selection along contour lines. Thank you!

I'm currently using Python version 3.7.6 and openCV version 4.2.0

edit retag flag offensive close merge delete

Comments

"are all the pixels along the contour line are included or just those in the inner side" sounds like a question you could have answered yourself through experimentation. As How To Ask Questions The Smart Way points out, failing to do due diligence hurts the chances that you'll get an answer by showing disrespect for the value of the answerer's time.

ssokolow gravatar imagessokolow ( 2020-03-23 20:54:13 -0600 )edit