GrayScale Output from Super Sampling

monochrome bitmap of circuit lines

Figure 1: Monochrome bitmap of circuit traces

When ripping small features at low resolution the results have jagged edges because the pixel size is roughly similar in size to the feature being rasterized. See Figure 1.

The problem is especially noticeable in lines that run at an angle.

What can be done about these jaggies? The brute force approach is to use a smaller pixel size (i.e. a higher resolution) until the jaggies shrink to where they are no longer visible. Such an approach is not practical since the mechanics of the imaging equipment may be limited and the time required to scan an area at a higher resolution (even if there are no mechanical limits) becomes costly.

grayscale bitmap of circuit lines

Figure 2: same resolution but pixels are gray scale.

There is a well known "trick" in the imaging industry that produces smoother edges without an increase in resolution. This involves modulating the energy of the laser beam pixel by pixel. At lower energies the effective spot size of the beam is reduced.

The reason that the lines in Figure 2 look much smoother is that it is a gray scale image; each pixel can take on a value from 0 to 255. Pixels that lie on the edges have their gray value modulated depending on how much of the pixel is "inside" the edge and how much is "outside" the edge.

Calculating Gray Levels with Super Sampling

pixels on the edge must be assigned an appropriate gray scale based on the percent of the area that they cover.

In order to assign gray levels to the pixels that lie on the "edges" the rasterization software has to oversample the input data. That is, if your final output is to be 1000 dpi then software must sample at some higher level (2000, 4000, 8000, 16000) in order to extract information about the edge. The higher the oversampling, the more levels of gray can be generated.

Consider the pixel locations labeled A, B and C. What gray scale value should be assigned to each of these pixels and how should it be calculated?

Gray Scale       1   2   3