This paper investigates the problem of extracting 3D shape from flat 2D images. In contrast with conventional methods, this work uses two images captured from the same position but under different illuminations to reconstruct a 3D shape. The proposed novel algorithm is based on an underdetermined system by seeking sparseness and statistical independence between direct illumination and object shape within a statistical estimation framework. The technology proposed surpasses the minimum requirement of the photometric method, which needs at least three input images. In addition, a new statistical model was developed which is updated by the Expectation-Maximization algorithm to accommodate the system noise appearing on the images. The performance of the proposed algorithm significantly increased the accuracy over conventional methods whilst reducing the computational complexity.