1. A three dimensional shape measurement apparatus for measuring a 3D shape of an object existing on a measurement area, comprising: a pattern projection unit configured to project a pattern having a periodicity onto the measurement area; and a capturing unit configured to capture an image of the area onto which the pattern is projected, wherein the measurement area is specified by a reference plane, a projection area of the pattern projection unit, and a capturing area of the capturing unit, and the pattern projection unit projects the pattern to be focused on the reference plane, and the apparatus further comprising: a phase information calculation unit configured to calculate phase information of a pattern of an image captured by the capturing unit when the object exists on the measurement area; a defocus amount calculation unit configured to calculate defocus amounts of the pattern in the captured image; and a three dimensional shape calculation unit configured to calculate a three dimensional shape of the object based on the phase information and the defocus amounts.