Most relevant OpenCV tool to find a square in a frame
To find a square and calculate its center on a frame taken by a webcam, what openCV tools could be recommended?
So many of them, diffucult to select the most suiatble for the purpose. I am not asking for code, I am asking an advice which particular OpenCV tools to study in details.
The details:
The real square to find on the picture is about 80mm by 80mm, white color surrounded with 10mm black frame. Inside the white square, in its center could be some small black pattern like circle, rectangle, triangle etc.
Picture is taken with a 640x480, 30 fps webcam from 2 meters through a red filter.
On the picture the square is roughly 25 by 25 pixels, it looks light gray with black frame (see picture). image:! C:\origin.jpg
The square migh appear anywhere within the webcam viewing field ( it is about 55 degrees). It does not move but may appear slightly turned. I.e. its upper and bottom edges may by not exactly horisontal. The backgoung might be noisy. Important is reliabibilty (no square should be missed and no false square should be found) and precision (the coordinates of the square center) The speed of the code is not important. PS. How shal I make the picture to appear in my post?
we can't see the picture
In edit...go to click image icon...then select choose image...select ok.....after that you will see text between square bracket...then enter description.
thank you. Do you see the image now? Please note that this is just a 70x70 pixels cut out of 640x480px frame. The rest of the frame is the same background. On this picture the worst case scnario is shown: noisy background with some faint square patterns and the lighting is not strong. Yet edge detection still shows the background pattern
Yes, I can see it.