1. An image processing apparatus comprising: a candidate position calculating section that calculates, from a given image, a first candidate position for a center point of a first circle tangent to three sides included in a detection target shape at three points; an angle calculating section that calculates angles formed by normals from the three sides to the first candidate position and reference lines of a uniform direction passing points where the normals and the sides cross; a relative relationship calculating section that calculates relative relationships of the angles with respect to the first candidate position; and a recognizing section that recognizes a shape included in the given image from the relative relationships of the angles and relative relationships of angles of a shape stored in advance.