Ask Your Question

iku317's profile - activity

2020-07-24 16:26:42 -0600 received badge  Popular Question (source)
2015-01-05 21:53:44 -0600 answered a question How can I write numbers inside the detected circles on the image when using Hough Circle Transform?

THank you very much . I followed your link and add the following code to the tutorial. However, the number can not be located around the center of a circle.

//For putting the numbers on the image; locate the center of the numbers to be putted on the image Point centerText(cvRound(circles[i][0])-radius/2, cvRound(circles[i][1])-radius/2);

  //Convert an integer to a string;
  ss << i+1;
  text = ss.str();     
  //Put the string on the image
  putText(src, text, centerText, fontFace, fontScale, Scalar::all(0),thicknessText,0); 
  //Clear the string;
  ss.str("");
2014-12-31 02:10:36 -0600 asked a question How can I write numbers inside the detected circles on the image when using Hough Circle Transform?

I used the Hough Circle Transform to detected around 2000~4000 circular wood columns. I followed the link below. http://docs.opencv.org/doc/tutorials/... my questions are:

  1. How can I write a number inside the detected circles? i.e. to write a number 1,2,3, to each of detected circle inside the red circle.

  2. How can I save the image of question 1 to a file so that I can later check the result?

Thank you all very much for your advice. Sincerely,