Pixels, PPI, DPI

Pardon me, but sometimes the Engineer in me has to rant. I see so much confusion about pixels and how to scale them to an output size. Pixels are just an RGB dot. How they are presented is up to the output driver. It is complicated at a technical level, but it does not have to be complicated to us poor users. So let’s see what pixels and PPI (pixels per inch) and DPI (dots per inch) really mean mean.

What are pixels?

A digital file is just a rectangular array of pixels. The term “pixel” is a contraction of “picture element”. It is the smallest dot the sensor can resolve or the smallest point of light a display can produce.

Getting to the array of pixels is complicated, since camera sensors don’t read them directly. See my article “How We Get Color Images“. Regardless of what magic actually happens, by the time you view an image on your computer monitor, it is an array of pixels. Conceptually each pixel is represented as a triplet of (Red value, Green value, Blue value). Each of the values is a number from 8 to 16 bits in size. So each value has a magnitude of 0 to 255 or 0 to 65536. What sizes you actually have is determined by the capability of your sensor (the dynamic range) and camera and the color space you are using.

Pixels have no physical meaning. In the main camera I use, the array is 8256 x 5504 pixels. Again, it is just a number. It has no physical meaning. It has no relation by itself to a print size or the size of the image on screen.

What PPI should I use for display?

This is the thing that annoys me the most. I constantly see museum and gallery directors put out requirement that we have to send in electronic samples sized to 72 PPI. PPI stands for pixels per inch.

Way back in the dim distant past, computers only did text. Then Apple came along and wanted to do graphics. They did research and decided 72 PPI looked good on screen. This set the standard, but hasn’t been the case for eons of computer age. The display on my fairly old iMac is about 218 PPI, physically. But the magic 72 PPI stuck with a lot of people.

The increases in PPI density and bit depth and speed of monitors is one of the great technological advances of computers in recent years. All those pixels on screen makes for very sharp and smooth images. We can see so much more.

Worse, many people have been led to believe that the PPI sizing of the image files means something. It doesn’t anymore. Actually, it never did for images displayed on screen. The PPI setting has little or no meaning for an image displayed on screen.

Try it

Try an experiment: take an arbitrary, fairly large jpg file of your choosing. Let’s say the filename is MyFile.jpg. Load it into Photoshop and resize, WITHOUT RESCALING, to 72 PPI. Save it as MyFile-72.jpg. Now reload the original file.jpg and size it to 360 PPI. Again without rescaling. Save it as MyFile-360.jpg. Rescaling changes the number of pixels in the file. We just want to change the PPI setting. These 2 files now have the same number of pixels but different ppi scaling.

Now use whatever image preview application you like and view the 2 sized files. Is one of them 5 times larger than the other? On my system, they are exactly the same size on screen. Even though one is set to be 72 PPI and one is 360 PPI. They are displayed as the same size and the same resolution.

Why is this? Because the file PPI setting means nothing. The display app just looks at the number of pixels and decides how large it is going to make it. If it is a tiny image, say 300×200 pixels, it will probably make it very small to avoid pixelization artifacts when an image is enlarged too much. It it is a reasonable sized file, it will just pick a good output size. It makes these choices based on the number of pixels. If the image is in a web page, the web page code determines the size the image will be.

What PPI should I use for print?

Now we head into an even more confusing area, and here the confusion is somewhat justified. Printing is it’s own special world. The technology and perception is very different from displays. Displays emit light. Prints reflect light. The effect to the viewer is very different.

Printers don’t have pixels. Instead, we refer to the output scaling as DPI – dots per inch. This recognizes that we are now talking about physical marks on paper (or your substrate of choice).

The printer manufacturers have created tremendous confusion in customer’s minds because they overload terms. The Canon Pro-1000 printer I have at my studio has a specified print resolution of 2400 DPI horizontally and 1200 DPI vertically. Yet the optimum print resolution is 300 DPI. That is, when I am creating a print, I should try to set the output resolution to 300 DPI. This is bound to confuse most people. Why not set the output to 2400 dpi for maximum resolution?

How inkjet printers make nice prints

We come to one of the secrets of printers. We customers want prints with crisp lines and smooth gradations of color and tone. As natural as film used to be, or as smooth as the original artwork we are copying. An inkjet printer sprays dots of ink onto the paper. A dot or no dot. At the level of a single dot, this is not smooth. Inkjet inks do not “mix” to create new colors.

So take my Canon printer as an example. Each “dot” (at 300 per inch) is actually subdivided into an 8×4 grid – 8*300 is 2400 dots per inch horizontally. Any position in this 8×4 sub-grid can contain any combination of printer dots of any of the 12 colors. The print driver uses a magical algorithm called “error diffusion” to cover the sub-grid with a blend of printer dots of the available colors that simulate the color and intensity of the pixel to be printed there.

It is mind bending in it’s complexity. One reason they don’t talk about it much is that it is proprietary for each manufacturer and printer, a closely kept trade secret. The good news is that they take over this complexity so we don’t have to. And they do a very good job. So I set my image to print at 300 DPI and magic happens.

It usually doesn’t matter

In summary, PPI settings do not matter for images displayed on your monitor or on the web or sent to your social media account. If someone tells you they need their images scaled to 72 PPI, just smile and do it, but secretly know they do not know what they are talking about. Only the total number of pixels affects the size of the image. And without going into mind numbing detail, I hope this takes a little mystery out of the way printing works.

I feel better now. 🙂 How about you? Are you more or less confused?

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.