# Determining the angle

• posted
Does anyone know some kind of symbol or sign that could be used in robot
vision to determine the angle at which some object is turned? Eg. There is
an object in front of the robot and through the camera it is needed to
determine at what angle is the sign turned (full frontal, tilted,...). Don't
know if I was clear enough, but thanks anyhow.
P.S. I heard there are some specific symbols developed for this, but I do
not seem to be able to find them on the Internet.
Yah!
• posted
Maybe a circle of lines radiating out at different angles. All lines being equal in length when viewed frontal no rotation?
A crude ascii version :)
\ | / -- + -- / | \
• posted
Yeah, I was thinking of some very simple versions but it seems like my resolution will be kinda low so there won't be any room for fine calculations (length, distances and so forth). But maybe it works... Gotta think about it...
• posted
Speculating, not speaking from direct experience, I'd expect that a distinctively colored circle would work best, especially if low resolution and processing power are important, the visual target is reasonably large (at least 5 or 10 pixels high or wide), and high precision is not required.
Speaking from experience, use HSV (*1) or a similar color scheme to detect the circle. Threshold (separate object pixels from background pixels) based on a formula like object=[abs(hue-orange)0.7 AND value>0.4]. Hunter's orange is easily identified in the average indoor setting. For microprocessor efficiency, rescale the HSV equations to values of 0-255.
If such a circle is viewed "full frontal", then you will see a circle; if viewed at an angle, you will see an ellipse. You can easily calculate this ellipse using the mean and moments of the pixel coordinates (*
2). Based on these axes, you can determine the axis of tilt (major axis of the ellipse).
If you also need orientation, then a second or third uniquely colored circle can be used. Looking at the vectors between the centers of these circles will yield orientation information, in addition to the previously obtained tilt.
I've seen other algorithms which rely on a checker-board pattern. They use edge detection to fit lines across the board. These lines are then used to calculate the board's position and orientation. These also seemed more processor intensive.
Have fun, Daniel
Quickly searched links: *1:
*2:
• posted
There's source code for a checkerboard-based aligner in OpenCV on SourceForge. The math needs some work; it sometimes reports totally bogus alignments.
John Nagle
• posted
In terms of resolution...
There are 2x as many green pixels as red or blue in a bayer color pattern. The blue are noisy as well.
RGRGRGRGRGRGRG GBGBGBGBGBGBGB