1. A method of detecting an edge of an object, comprising the steps of: lighting, in each one of a plurality of different directions, at least a portion of the object, taking an image of said portion of the object and a vicinity of said portion which are lighted in said each one of the different directions, synthesizing the respective images of said portion of the object taken by lighting said portion in the different directions, and detecting, based on the synthesized images, an edge of said portion of the object.