detect circle between some shapes

hi,in my image has some shapes(circle,square,triangle) . how can I detect circle between other shapes? and can tell me how many circle there is in my image.thanks in advance

Risposte (1)

Image Analyst
Image Analyst il 18 Mag 2013

0 voti

Have you tried imfindcircle() in the Image Processing Toolbox? Otherwise try hough() or somehow find all the objects and extract the circles based on their circularity = perimeter^2 / (4*pi*Area).

3 Commenti

i wrote my code according imfindcircle() , but it didn't work.
I = imread('c:\safa\test.bmp');
b=rgb2gray(I);
[centers, radii, metric] = imfindcircles(b,[5 30]);
viscircles(centers, radii,'EdgeColor','b');
subplot (2,3,1), imshow (b);
You forgot to tell us where you uploaded test.bmp.

Questa domanda è chiusa.

Richiesto:

il 18 Mag 2013

Chiuso:

il 20 Ago 2021

Community Treasure Hunt

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

Start Hunting!

Translated by