I am trying to extract contour from gray label image. My interest is I want to access/show numerical value of chain code. How can I do this? Here is my code segment.
int main(..)
{
Mat src_gray;
//read src_gray;
Mat canny_output;
vector<vector<Point> > contours;
vector<Vec4i> hierarchy;
int thresh=100;
/// Detect edges using canny
Canny( src_gray, canny_output, thresh, thresh*2, 3 );
/// Find contours
findContours( canny_output, contours, hierarchy, CV_RETR_TREE, CV_CHAIN_CODE, Point(0, 0) );
///Want to see chain code of contour here/How to access chain code value?
}