I need to detect the white rectangles and get their coordinates on an camera input like this:
i've been reading and i think i need to put a hsv filter and then apply threshold to the input. but then, for the tracking part i read about three methods: fincontours, houghline, and cvblob. but im not really sure of which one would be the best/simplest for this kind of uniform objects with the same color. specifically, i need to know the coordinates of the borders, because i need to know whether if another object is inside one of the lines (and in which one) or in the middle of two. any advice is appreciated.
the camera will be just the top of the street, so in the application they will be rectangles. i just didn't find an image like that in google.
As @Miki stated, those are not rectangles. They are rectangles that affected by a perspective transform. You should look for quadrilateral detection. This is not an easy task if you want it to be general purpose.
EDIT:
Depending on your edit, to detect rectangles in an image you need some other measurements. Becuase applying a rectangle detection algorithm will results in many false positives in your case.
Rectangle Detection:
Isolate needed rectangles:
You will got many false positives. So, you need filter them. From the little information you gave, it is hard to tell how to filter them. But color should work fine. Just remove the rectangles with the color that it is not desirable.
You many also depend on the alignment of the rectangles.. you can isolate rectangles that are not vertically alignment with the others