OpenCV  3.4.4
Open Source Computer Vision
samples/cpp/contours2.cpp

An example program illustrates the use of cv::findContours and cv::drawContours

WindowsQtContoursOutput.png
Screenshot of the program