1. A method of calibrating shading non-uniformity of a camera module comprising the steps of: capturing at least two sets of flatfield images from at least two sets of camera modules under first and second illuminant, respectively; averaging an array of pixels of the at least two sets of N flatfield images to form first and second averaged flatfield images, respectively; transforming the first averaged flatfield image using the second averaged flatfield image to create at least one transform image; and saving the one transform image in a memory for calibrating the shading non-uniformity of the camera module.