User Manual - twentynine
In comparison with the bilinear interpolation, the
HQ Linear interpolation
method has the modest increase
in computational complexity. However, the main advantage of this method is that it generates significant
higher quality color images with greatly reduced edge artifacts. Therefore
HQ Linear interpolation
is in the
CameraSuite SDK
used as the standard demosaicing algorithm.
Pixel Group Interpolation
Pixel Grouping
is another interpolation method considering pixel values in a 5x5 neighborhood to calculate
missing color values. It basically works in two phases; first it computes all the unknown green values, and
then it uses the input data along with the green values computed in the first phase, to compute all the
missing red and blue values. The main principle is to determine the gradients in the four directions from
the current processed pixel and select the value with the smallest one for final calculation. The smallest
gradient value is chosen to reduce edge artifacts due to the fact that a higher gradient value is an indication
for edge transition.
In comparison with the
bilinear
and
HQ Linear interpolation
methods,
Pixel Grouping
is the most memory
and computational intensive algorithm. However, the result color image is at very high quality with very
little edge artifacts, especially for scenes with large areas of uniform colors that are separated by clear
boundaries.
Colorized Output
The Colorized algorithm is not doing any interpolation. It simply creates an intensity Bayer RGB color image
by setting the missing color values to zero. The intensity value of the current pixel remains unchanged.
Restrictions at the Image Borders
Nearly all interpolation methods have problems at the borders of the image. Depending on the size of the
filter used (3x3, 5x5, ...), one or more neighbors in each direction are needed for interpolation; at the borders
at least one direction is not available, like illustrated in Figure 108 and Figure 109 for
Bilinear
and
HQ Linear
.
Figure 108: Bilinear algorithm border
Figure 109: HQ Linear algorithm border
The ImageProcAPI therefore provides four approaches:
•
leave border pixels as original (RAW)
•
cut off border pixels
•
fill border pixels with a solid color
•
interpolate border pixels with a specific demosaicing algorithm
132
SMARTEK Vision | User Manual - twentynine | Doc. v1.0.2