Have you ever wondered how computers store, print, and display images? Well that’s the topic for this week’s article. Computers are actually not all that smart when it comes to storing image information. They really only store numbers, as a sequence of ones and zeros. So how do they keep a photo?
A photo, as far as a computer is concerned, is a grid of numbers that represent the colors in the image. Each spot on the grid holds four numbers between 0 and 256, one for each of four colors. If the image is meant for viewing on a screen, it usually uses Red, Green, Blue, and Alpha (RGBa). The higher the number, the darker the color. Alpha is the transparency of the image; since images can be overlaid on a computer screen, it is necessary to tell what happens when they overlap. If the image is meant to be printed, then it is usually stored using Cyan, Magenta, Yellow, and Black (CMYK). This has to do with the differences between how colors of light mix, versus the colors of ink.
There are two things needed to tell the computer the proper size to display an image. The first is the physical size of the image, for example, a standard photo is four by six inches. The second number tells how many pixels, or rows and columns of numbers, to store to represent the image. This can be defined as either the total width and height in pixels, or as a ratio of pixels per inch. Many common modern digital cameras capture images in the rough size of eight megapixels, or about eight million pixels. This is a grid that is 3266 by 2450 pixels, which gives you 8,001,700 pixels. Notice that this megapixel definition does not provide a size in inches, so the pixels per inch can be changed to make an image much larger or much smaller.
How big can you print the photo? As big as you want, but if there are not enough pixels it will start looking like a mosaic of little squares instead of a smooth image. The general rule is not fewer than 300 pixels per inch. So in the case of an eight megapixel image, this is 3266/300 (or 10.89) inches by 2450/300 (or 8.17) inches. You see each pixel is a box of color; the more boxes you have per inch, the clearer the image. This is true in both print and on your screen.
Pixelation is used by many websites to make it nearly impossible to print their photos. How can a picture on a website look great on the screen and bad when it is printed? Because it has too few pixels. Most websites display images less than five inches wide, at 100 pixels per inch. This makes an image 500 pixels wide. From the math above, the largest image you can print clearly is only 500/300 (or 1.6) inches wide. If you try to print an eight by ten photo from this web image, you will only get 62 pixels per inch, which means you will easily see the square shapes of the pixels and have a very poor print.
You can sometimes fix low-resolution images with photo editing software like Photoshop, by using their resize options. You can usually double the size of the image by re-sampling the image at the higher resolution before causing it to start losing quality. Basically what the computer does is makes a new pixel for each pixel. Based on the color of the copied pixel, it will match the color, blend the color with that of the neighboring pixel, or match the neighboring pixel’s color. This magnifies any issues with the original photo so you cannot go much bigger.
That is a little bit about how computers store, display and print images. If you see a picture in The Licking News that looks pixelated, you know that the publisher likely started with a low resolution image and did their best to bring it to print quality. Submissions many times are fine quality for the internet but too small for good printing. The difference between screen resolutions is 72 pixels per inch on most phones and 300 pixels per inch in newspaper print. What looks fine on your phone may look bad on paper and now you know why.