imfindcircles - convert centers to pixels on image
2 次查看(过去 30 天)
显示 更早的评论
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.
0 个评论
采纳的回答
Keerthana Chiruvolu
2020-3-3
Hi,
Refer to the following link for a demo: https://www.mathworks.com/help/images/ref/imfindcircles.html?#btdxntz-4
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.
0 个评论
更多回答(0 个)
另请参阅
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!