Showing results for 
Search instead for 
Did you mean: 

best way to find circle shape in moving view

Hi, I have myrio 1900. I`m doing a robot car with web camera that needs to scan the room and find a purple ball. I use vision assistent. First I tryed to find the ball by color (purple) but the color detection is good for the range that the color was first sampled (if I sampled in 1 meter than in 5 meters it wont recoginze purple). So I decided to find the shape by its circle dimentions. I tryed to use canny filter and shape detection but because the background has a lot of shapes (for example its not a clear wall and a ball....instead there are chairs, tv, and a ball) it doesnt recoginze the circle shape of the ball. What is the best way to find a circle shape in a background that has lots of shapes? Thanks,
0 Kudos
Message 1 of 9
Try using both..!!

IF possible put some visible mark/shape on ball which can be detected as pattern match.
0 Kudos
Message 2 of 9

no  LVKrAkEn, it doesnt work very well....


I tryed to use in Vision Assistant -> "find Circular Edge". This finds my ball and mark circle around it. But when I exit the Vision Assistant and press play -> the circle stays at the same place (the place I configured it in the vision assistant ) even when I move the ball. 

Why is that? How can I change it that "find Circular Edge" always detect the ball even when it moves?



0 Kudos
Message 3 of 9

Hello can you send us some screenshots of you vision assistant configuration? 

Randy @Rscd27@
0 Kudos
Message 4 of 9

I would combine both ways: object can be not perfectly purple and not perfectly circular, but you will still find it.

I would look first at Value color plane. Binarize based on range of "purple" colors.

Then fill holes - bright spot will be white.

Then Filter particles based on roundness and range of sizes.



0 Kudos
Message 5 of 9
0 Kudos
Message 6 of 9

Hi Sir,

     In my project I need to find the circular region of an object. The object may move so I have to design it in such a way to detect the circle how much ever it moves. Can any one help we with a VI for me to process. I am using a 16 bit Monochrome image in my project. I saw the above discussion I tried it also but its not working for me. Kindly give me some vi for me to work

0 Kudos
Message 7 of 9

You do realize, I hope, that this is a somewhat difficult problem, involving one of the more esoteric aspects of LabVIEW, namely the Vision module.  Do you consider yourselves reasonbly accomplished with using LabVIEW, i.e. do you know how to write good LabVIEW code without using Express VIs?  Do you understand the process of Object Detection in Images?


If this is a Homework (or other "education") assignment/project, then you should do as much of it as you can, then post your code (no pictures, please, and try to post the entire LabVIEW Project, compressing the folder with all of your VIs and attaching the resulting ZIP file).  If this is a Work assignment, then team up with other LabVIEW Developers in your company and brainstorm together, possibly going to the LabVIEW Developers for Hire Forum here in the Community if necessary.


Bob Schor

0 Kudos
Message 8 of 9

Thanks Bob. I have worked on it and completed the code.

0 Kudos
Message 9 of 9