Method FindContoursAsMat
- Namespace
- OpenCvSharp
- Assembly
- OpenCvSharp.dll
FindContoursAsMat(InputArray, RetrievalModes, ContourApproximationModes, Point?)
Finds contours in a binary image.
public static Mat<Point>[] FindContoursAsMat(InputArray image, RetrievalModes mode, ContourApproximationModes method, Point? offset = null)
Parameters
imageInputArraySource, an 8-bit single-channel image. Non-zero pixels are treated as 1’s. Zero pixels remain 0’s, so the image is treated as binary. The function modifies the image while extracting the contours.
modeRetrievalModesContour retrieval mode
methodContourApproximationModesContour approximation method
offsetPoint?Optional offset by which every contour point is shifted. This is useful if the contours are extracted from the image ROI and then they should be analyzed in the whole image context.