Resolution of
Digital Cameras: How Much is Needed and How Much Have You Got?
Introduction
We are concerned with
pixels and resolution because we want
our pictures to look good. Therefore the two basic questions concerning
resolution are how much we need, and how well does any particular
camera do? Here we are assuming that printer capabilities are not
limiting. In the past, when
film was used to record photographic
images, it was logical that lens resolution be described in terms of
distances
on the film, e.g. the number of line pairs/mm that could be resolved.
With the
shift to digital photography, the elimination of film, and the
understanding
that resolution of an image depends somehow on the number of pixels in
the
camera’s sensor, “resolution” is now more often described in
terms of
number of pixels in the image. Only if the optics are sufficiently
good,
however, is counting the pixels an adequate measure of a camera’s
resolution. If a camera lens is of low quality and spreads the image of
a point
over a number of pixels, then the camera’s resolution will be less than
that
suggested by the number of pixels in its sensor. Not surprisingly,
measures of a camera’s resolution other
than lp/mm or pixel counts are gaining in popularity. One the most
meaningful
measures is the number of line pairs (one black line and one equal
width “white
line”) that can be resolved per picture width, lp/pw or picture
height.
How Much Resolution Do We Need?
The amount of detail that is needed in an image
depends on one's use of the image. If we are examining prints, then the
question becomes determining the limit of resolution of the human eye
when examining prints. I tested my resolution under the light
conditions under which I display my prints. The test used the target of
line pairs described and provided below.
At a distance of 13 feet (156 inches) I can just tell that the bottom
pattern of the most closely spaced 20 line pairs, which is in total 1.6
inches wide, is indeed a set of vertical black and white lines and not
a gray rectangle. If I were viewing a 4" x 6" print from a distance of
18", the number of line pairs that I could just distinguish across the
6" would be 20 x 6/1.6 x 156/18 = 650. Thus, a camera able to
resolve 650 line pairs across a picture width generates as sharp an
image as my eyes are capable of discerning. Any greater resolution is
unnecessary as long as I don't significantly crop an image before
printing. I find that I observe 8" x10" images from about 36" and
13" x19" images from about 60". These sizes and distances turn out also
to require a resolution of about 650 line pairs per image width. As
shown below, a good prosumer compact digital requires about four pixels
to resolve a line pair This corresponds to about 2500 pixels across an
image and 1667 pixels from top to bottom, giving an active sensor size
of a little over 4 megapixels. Leaving space for cropping, it seems
that 6-7 megapixels is the maximum sensor size one would ever need--if
the optics are adequate.
My eyes under the lighting I used can just resolve 0.6
line pairs/arc-minute, arctan(1.6/20 x 1/156). This is somewhat less
than the limit of human resolution that is about 1.7 line
pairs/arc-minute. Possibly then, an argument can be made for using
cameras with sensors capable of resolving 2000 line pairs across an
image, which would require a sensor of about 24 megapixels. Clearly,
there is no need for anything larger than 24 megapixels. If when you
print the line pair image given below at 8.5" x 11" and you can tell
from a distance of 39 feet that the bottom set of line pairs is truely
line pairs and not a grey rectangle, then you need 24 megapixels. I
don't.
A Direct, but Subjective
Measure of Resolution
A good idea of the quality of a camera's resolution
can be obtained merely by looking closely at how well it images
an edge. If the sharp edge of a black rectangle is imaged on the center
of a pixel, then its output response should be the average of the white
response and the black response, a mid level gray. The pixel
immediately to one side of this central pixel should be full white, and
the pixel on the other side should be full black. Blur in the
optical system will smear black into the white area and white into the
gray area and may generate a band several pixels wide over which the
transition between white and black occurs. Close examination of
such pixel densities requires the use of an image editing program
capable of enlarging images to the point that individual pixels are
easily discerned. The programs ImageJ, Picture Window Pro, and
Adobe Photoshop are all capable of such magnification (See related web sites below.)
A portion of the greatly enlarged output in jpeg format
from my Canon S70 camera of a white-black edge is shown below and
reveals an interesting feature. The image was exposed
such that the white areas were not fully white in the exposure, that
is,
not of intensity 1.0, and the black areas were not fully black, that
is,
not intensity 0.0. Just to the side of the edge are several pixels that
are whiter than those away from the edge. Similarly, on the other side
of the edge are pixels that are more black than those away from the
edge.

These enhanced
contrast areas are a result of digital sharpening (see The
Principles
Behind Digital Image Sharpening) of the image that has
been performed in the camera as it converts the information recorded by
the sensor into the final jpeg format file of the image. This
sharpening
is always performed by
the camera when it stores images in the jpeg format. While it generally
enhances the picture quality, it
does not always do so. For the most refined computer-based image
editing, it is best that this in-camera image sharpening be
prevented. As we will see below, sharpening affects measurement of the
optical resolution of a camera.
Many cameras allow images to be stored in raw format in addition to jpeg format. The raw format images are not sharpened, and computer programs for the conversion of raw files allow sharpening to be omitted from the conversion of raw to jpeg or tiff files. The illustration below shows another highly magnified portion of an image of a white-black boundary. This image was converted from raw to tiff format without sharpening. The extra-white and extra-black halos from sharpening are absent. The target was slightly tipped with respect to the camera so that the edge would fall in varying positions on the pixels. At its narrowest, the transition region from white to black encompasses three pixels. At such a point, as illustrated, the edge must have fallen close to the center of the middle pixel in the transition. Clearly some black blurred into the adjacent pixel and some white blurred into the pixel on the other side. Thus, we can see that the camera blurrs significantly beyond half a pixel but not much beyond one and a half pixels.

An
Objective Measure of Resolution
Before
proceeding, it is helpful to provide an objective measure of
resolution. It is
the modulation transfer function, MTF, that can be defined for
black-white line
pairs. Take a cross section of the output from a perfect optical system
that is
generating an image of the lines on a sensor, and let the sensor
consist of
infinitely small pixel elements. Pixels recording the image will see
light of
intensity 0 for the black lines and intensity 1.0 for the white lines.
The MTF
of an image of the lines is defined as the maximum intensity difference
between
a pixel imaging a black line and a pixel imaging a white line divided
by the
intensity difference between white and black areas when blurring is
irrelevant
(taken from large areas of black and white on the image). In the case
of a
perfect optical system in which there is no blurring or spreading of
images,
MTF = (1.0 – 0.0)/ (1.0 – 0.0) = 1.0

Resolution With Finite-sized Pixels
A highly
imperfect optical
system could blur the lines and completely mix them. In this case an
image of
line pairs is recorded as uniform grey, 50%. Images of large black and
white
objects would still contain regions of intensity 0 and intensity 1. The
MTF in
this case equals (0.5 – 0.5)/(1.0 – 0.0) = 0.

The drawings below show that, even with perfect opics, as
the number of line pairs increases, the MTF must drop from 100% to 0%.
Thus a
reasonable measure of the optical quality of a camera is how much more
rapidly
the measured MTF decreases that it would if the optics had been
perfect.
Suppose
the widths of the lines are such that a line pair has a width
approximately
equal to the width of one pixel. In this case, the number of line pairs
across
the image, lp approximately equals the pixel width of the
image, or lp ≅ pixels wide. No matter what the exact phasing of line
pairs is on the pixels, each
pixel images the equivalent of one black line and one white line and
its output
will be 0.5. Thus, the MTF in this case, even with perfect optics, is
0.
If
the number of pixels across the image is doubled or the number of line
pairs across the image is halved, lp ≅ pixels wide/2. Equivalently, this is two pixels per line
pair. In this case sometimes pixels will line up
exactly
in register with the lines
and with perfect optics, the local MTF in this little region will be
one. At
other places across the image, the pixels will not be exactly in
register. (Let
us ignore the special and physically unrealistic case of line pairs
exactly
matching the pixels, pixel for pixel across the entire image.) For
every place
across the image that they are perfectly in register and give a MTF of
1, there
will be a place where they are perfectly out of register and have a MTF
of 0
and so on. Averaged across a significant portion of an image, the MTF
equals
0.5. If the optics are less than perfect, the areas of black and white
will
spread somewhat into each other and the minimum intensity by any pixel
recording a black line will be greater than 0 and the maximum pixel
intensity
of a white line will be less than 1.0, and as a result, the MTF will be
lower
than 0.5.

If the number of pixels across the image is doubled again, lp ≅ pixels wide/4, that is, four pixels per line pair,

then with
perfect optics, no
matter what the precise positioning of the lines with respect to the
borders of
the pixels, one pixel will receive a full black image and the pixel two
positions away receives a full white image. Thus, with perfect optics
the MTF
is 1.0.
With
a little effort one can show that the theoretical best MTF for one line
pair
per three pixels, lp ≅ pixels wide/3, is 0.75. The precise behavior of MTF as a
function of line pairs per
pixel in this range is quite interesting, but not important for our
questions.
The
end result of our analysis is that one measure of the optical quality
of a
digital camera can be obtained by comparing the measured MTF when
imaging the
vertical black and white lines in the region of two to four pixels per
line
pair, that is at lp ≅ pixels wide/2 to lp ≅ pixels wide/4. In this
latter case, a good optical system will
have an MTF close to 100%.
Measuring Resolution
It is relatively easy to make resolution measurements by
photographing
a target containing groups of 10 or 20 appropriate lines (ranging
from 5 to
20 line pairs per inch) from a distance
of 5 to
15 feet, then analyzing with an image editing program like Picture
Window
Pro, Photoshop, or ImageJ. It should also
be possible to display a suitable target on one's monitor and
photograph that. From the
pixel positions of the edges of a set of lines and the total number of
pixels
across
the image, calculate the total number of line pairs possible across the
image.
Pick images and sets of lines where lp is
close to pixels wide/4.
Measure the lightness value of the image in white areas and
black
areas and
then expand the image and read out the lightness values across several
black
and white lines to obtain the MTF by comparison to the white and dark
values.
An optical
target for use in resolution measurement.

Downloadable
version of the above target (0.5 MB).
Resolution Measurements on a Canon S70
The
table below shows the maximum possible MTF as a
function of line pairs per pixels wide and the values obtained with a
Canon S70 high end consumer camera with images stored as jpg files and
with images converted from raw format with no sharpening. At lp ≅
pixels wide/4
the camera does well both in wide angle and telephoto in both the
center of the image and in the corners. Surprisingly, however, the
resolution falls unexpectedly rapidly at greater resolution. As one
would expect, (The Principles
Behind Digital Image Sharpening), sharpening can enhance detail, as
shown by the fact that at pixels per line pair = 4, the MTF of a
sharpened image is 0.8 whereas without sharpening it is 0.4. Sharpening
is incapable of generating resolution where there is none, that is, at
pixels per line pair =2.
| Pixels per
line pair |
Maximum MTF
Possible (Perfect Optics) |
S70 Wide, Image Centered f 2.8, 5.8 mm (28 mm) JPEG format |
S70 Wide, Image Corner f 2.8, 5.8mm (28mm) JPEG format |
S70 Tele, Image Center f 5.3, 21mm (100mm) JPEG format |
S70 Tele, Image Corner f5.3, 21 mm (100mm) JPEG format |
S70 Wide, Image Centered f 2.8, 5.8mm (28 mm) Converted from raw, no sharpening |
|---|---|---|---|---|---|---|
| 1 |
0 |
- |
- |
- |
- |
0 |
| 2 |
0.5 |
0.0 |
0.0 |
0.0 |
0.0 |
0 |
| 3 |
0.75 |
0.28 |
0.13 |
0.0 |
0.0 |
.08 |
| 4 |
1.0 |
1.0 |
0.8 |
0.84 |
0.86 |
.4 |
http://www.clarkvision.com/index.html.
This site has nice pictures and a very thorough analysis of imaging and
sensors.
ImageJ, http://rsb.info.nih.gov/ij/index.html.
This wonderful program is free. It is directed towards quantitative
analysis of
images.
Picture Window
and Picture
Window Pro, http://www.dl-c.com/.
This is an
inexpensive but very powerful program is designed for serious
photography and
serious photographers.
Norman Koren's
site,, http://www.dl-c.com/, http://www.normankoren.com/Tutorials/MTF.html, provides excellent tutorials on
many aspects of digital photography, including resolution analysis and
MTF as well as the use of Picture Window Pro.
Clark Vision,
very nice
site, http://www.clarkvision.com/.
This is another excellent site with wonderful tutorials and beautiful
pictures.
Imatest, http://www.imatest.com/. This
commercial
site and bulletin board sells and services a program for analysis of
lens
resolution developed from the ideas that are described on Koren’s site.