Posted by: recordingsofnature | August 26, 2014

Effect of pixel fill factor on aliasing and Moiré

This is an investigations of how the pixel fill factor in the image sampling process influences aliasing and Moiré. It is here done by use of a sampling simulation (terated as simple mono chromatic – no Bayer filters etc.)  just to illustrate the fundamental aspects.

The low pass filtering is an essential part of any image sampling process, serving to eliminate any high frequency component that cannot be reproduced with the given sampling rate and resolution. Any frequency detail above half the sampling rate (Fs/2= the Nyquist rate) will be reproduced as mirrored and aliased frequency artifacts, only contributing with artifacts and noise to the sampled image.


Test chart with indication of locations of the harmonics of the Nyquist frequency

Test chart with indication of locations of the harmonics of the Nyquist frequency= Fs/2 of the sampled image. The original high resolution chart found here.

In digital image sampling, the low pass filtering is typically done directly on the image sensor by the pixel window/aperture it self. That means the filter function can be described by a rectangular/square window function, which has a sinc-shaped transfer function. The pixel fill factor, seen as the percentage of sensor pixel coverage (pixel width^2) over the whole pixel spacing area, determines the pass band and stop band ripples. As will be seen in the simulations, even a 100%l fill ratio will not produce a perfect low pass filter, which effectively removes aliasing.

Image test chart
The simulations are made with the above test chart, which contains an image and various line bar patterns. In the simulations the test chart  is sampled using 8 x 8 pixels for each sampled pixel. With this sampling rate the harmonics of the Nyquist frequency (= Fs/2) corresponds to the arrows on the figure.

For a perfect sampling process all line densities above the Nyquist frequency should appear uniform gray, while the line densities below should appear well defined, gradually fading into gray at the Nyquist frequency. When the sampling has insufficient low pass filtering, high frequency line patterns will leak into the image forming disturbing artifacts and Moiré banding (aliasing).

Fill factor simulation results
Lets see the results when the rectangular pixel fill factor is varied from 12.5 x 12.5% to 100%.

12.5% x 12.5% fill factor12.5 x 12.5 % fill factor

25% x 25% fill factor25 x 25 % fill factor
50 x 50 % fill factor50 x 50 % fill factor
75 x 75 % fill factor75 x 75 % fill factor
100% fill factor100 % fill factor

A lot of aliasing is seen, especially for the low fill factors. The result is a very sharp but also noisy and low quality appearing images. This is also shown by the line patterns, which features lots of banding way above the Nyquist frequency.

As the fill factor approaches 100% the low pass filtering improves, but even for a 100% fill factor a great deal of high frequency components are passing through and present above the nyquist frequency. Here, the response is 0.64 at Nyquist fading to first zero at 2 x Nyquist (as also depicted by the Sinc function). This is also clearly seen on the line RMS curves.

Even though the image looks good at 100% fill factor, it actually contains quite a lot of aliasing and artificial sharpness, which is actually not supposed to be there. If used in a moving picture, -lets say the image is panning, this aliasing will become flickery and disturbing.

The artificial sharpness due to aliasing becomes more clear when some extra sharpness is applied in a post processing step.

50 x 50% fill factor + sharpness50 x 50 % with enhanced sharpness
100% fill factor + sharpness100% with enhanced sharpness

After applying sharpness, it is now clear that something is not right, and the image quality just looks like old cheap HD video.

It is clear that the rectangular pixel aperture low pass filtering is far from ideal.

Gaussian pixel apperture

The theory tells, that a much better low pass filtering can be achieved by using a the pixel aperture with the shape of a Gaussian distribution function.

Let’s look at how a Gaussian shaped pixel aperture performs. The width of the Gaussian distribution, will determine the cut off frequency. Here, I have adjusted the size manually for what looks to be the best performance:
Gauss24Gaussian pixel aperture
gauss24 + sharpnessGaussian pixel aperture with enhanced sharpness.

Compared to the square pixel, the unsharpened image seems a bit blurred. However the linebar diagram actually indicates very good performance with very little frequency components are present above the Nyquist frequency. . Line bar patterns show a nice even gray appearance for frequencies just above Nyquist x1.  This image quality is actually a much better and more correct representation, based on the available pixel resolution, even though the image detail is reduced. After applying additional sharpness the test chart actually looks very good, and the line bar charts indicate that still only very limited aliaisng i taking place.

In comparison to the 100% square pixel sampling, the Gaussian distribution pixel has a distinct smoothness and analogue feel. Seen from a theoretical view this image is much more correct.

Applying simple blur filter as antialiasing filter

In practice the Gaussian distribution pixel aperture is difficult to realize, however it can be effectively approximated by use of an external optical aliasing filter (low pass  filter) applied before the pixel sensor.

Lets see the effect of adding a bit of simple optical blur in addition to the square pixels. In the simulations, the optical blur has been modeled by a simple blur disk (circle of confusion) with a diameter of 1.5 and 2 pixel diameters (of the sampled image  resolution). The total sampling filter is now the pixel aperture convoluted with the blur disk.

First for the 50 x 50% pixel fill factor:

50%+cyl1650 x 50% fill factor + 2 pixel wide blur disk
50% fill+16 cyl+sharpness50 x 50% fill factor + 2 px wide blur disk  + sharpness

The same simulations now with a pixel with 100% fill factor:
100% fill + cyl 12100% fill factor + 1.5 px wide blur disk
100% fill + cyl12+ sharpness100% fill factor +1.5 px wide blur disk + sharpness

The sampling filter of the combined blur disk and square pixel aperture now starts to look like a normal distribution and similarly the high frequency component are effectively removed. The results are actually quite comparable.

Use of simple optical antialiasing blur filters may save a lot of technical and computational challenges for digital moving pictures systems.



  1. […] The test chart used, is a customized chart designed to give a quick overview of aliasing and Moiré performance for horizontal and vertical lines, as well illustrating the general image quality. A similar test chart is used in this post on Pixel fill factor. […]


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s


%d bloggers like this: