Adaptive PGA
The Positional Gain Adjustment (PGA) corrects for lens shading and color shading artifacts across the sensor image area. If the Adaptive PGA tab in SensorTune is active then this device features Adaptive PGA (APGA). APGA adjusts the PGA dynamically according to the scene illuminant color temperature to further correct the illuminant-dependent color shading artifacts.
To calibrate the APGA requires capturing three raw images of a uniform gray lens shading calibration target under three different illuminants.
Acquire Three Calibration Images
The images must be raw Bayer or YCbCr data, and can be loaded from files or acquired directly from DevWare if DevWare is running concurrently. Using Bayer data is highly recommended, but it is not always possible to collect Bayer data from the target camera system. In that case YCbCr data can be used, but the green channel calibration will be somewhat compromised. The Bayer data should be collected with the sensor in the SOC Bypass mode, not the Processed Bayer, which has been through the SOC color processing. If YCbCr data is being used, then all color enhancement should be disabled, especially color correction matrix and gamma correction.
Select or enter the color temperature of each illuminant in the boxes.
Image Data Details
Select whether the data is Bayer or YCbCr, and click More Details... to enter additional image data information needed by the calibration calculations. Files of type .RAW have no header information, so this information has to be entered manually. If the images were captured directly from a concurrently running DevWare then most of these will be filled in automatically.
It is expected that the calibration image dimensions will be the nominal full size sensor output. For example 1280x960 for MT9M114 (SOC1040). If the image is larger then it will be automatically cropped equally on all sides. If that is not correct, then override the cropping on the More Details... dialog.
For Bayer images, More Details... button brings up a dialog with the following fields:
For YCbCr images, More Details... button brings up a dialog with the following fields:
The Full Range and CCIR-601 buttons select the two most common sets of values for these fields.
Output File
Enter or browse for the name of the output file. The output will be a plain text file in the DevWare .ini file format.
Calibration Parameters
Select or enter the desired brightness falloff parameter in the box. The falloff is the brightness at the left and right edges of the image after correction, as a percentage of the peak brightness.
Optionally, click More Calibration Parameters... to change other parameters to the calibration calculation. Normally these can be left at their default values. The button brings up a dialog with the following fields:
Calibration
Click Calculate button to run the calibration calculation. The results will be written to the output file.