imfindcircles - convert centers to pixels on image

2 views (last 30 days)
Hello reader,
Unfortunately I am unable to extract the centers of my circles using imfindcircles.
Let me elaborate: I have a binary image, I use imfindcircles to detect the circular feature within it. And up to this point everithing is fine.
However, I would like to extract the circles drawn and make a binary image out of the full areas of the circles.
So one way which came to mind is draw white circles on a 0 value backgrown image, the size of my original image. but I am unable to do so as I do not understand in what value the "center" array (generated by imfindcircles) is expressed. By getting the position of my current figure (get(gcf)) none of the make sense as I initially thought that the centers were expressed relative to this.
Could you help me to extract the center pixel related to the one which was calculated by using imfindcircles?
Please find attached here a visual example of what I mean.
Thank you, even only for having taken the time to read.

Accepted Answer

Keerthana Chiruvolu
Keerthana Chiruvolu on 3 Mar 2020
Hi,
Kindly have a look at the Tips section of the documentation (imfindcirlces) for more insights.
Alternately, you may use the regionprops() function to specify the property you want to extract from the image. Centroid property returns the center of the circle.

More Answers (0)

Categories

Find more on Images in Help Center and File Exchange

Products


Release

R2018a

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!