Insights / Deep Dive

A camera sensor is a grid of tiny buckets

Every photo starts as a count of photons. Here is how a sensor turns light into numbers, why it needs a trick to see colour, and why dark photos are noisy.

Deep Dive18 Oct 20263 min readphotographyhow things worksensors

A camera sensor does not record a picture. It counts light.

Behind the lens sits a chip of silicon covered in millions of tiny light detectors, called photosites. Each one is a bucket. When the shutter opens, light falls into the buckets for a fraction of a second. When it closes, the camera reads how full each bucket is. That grid of numbers is the photo.

Everything else, including colour, sharpness and the look of the final image, is built on top of that count.

Light becomes charge

Light arrives as photons. When a photon hits the silicon in a photosite, it can knock an electron loose. Those electrons are collected and held in a small well. More photons in means more electrons stored.

A photosite can only hold so many. A small pixel in a phone holds on the order of ten thousand electrons or fewer. A large pixel in a big camera holds many times that. Once a well is full, extra light has nowhere to go, and that pixel is pure white. That is what "blown highlights" means.

From charge to a number

At the end of the exposure, the sensor turns each well's charge into a voltage, amplifies it, and passes it to a converter that writes it down as a number. A raw file from a modern camera stores that number with 12 or 14 bits per photosite, which means thousands of possible brightness levels.

Photosites are colour-blind

Here is the surprise. A photosite only knows how much light arrived, not what colour it was.

To get colour, a grid of tiny filters sits on top of the sensor. Each photosite sits under a red, a green or a blue filter, in a repeating pattern called a Bayer pattern. In every block of four, two are green, one is red and one is blue. Green gets half because our eyes are most sensitive to it.

So each pixel records only one colour. The other two are missing. The camera fills them in by looking at the neighbours and making an educated guess. That step is called demosaicing, and it means a lot of the colour in your photo is estimated, not measured.

Why dark photos are noisy

Light comes in discrete packets, and photons do not arrive on a schedule. If a pixel should catch about 100 photons, it might catch 92 one time and 108 the next. This randomness is called shot noise, and it is physics, not a flaw in the camera.

The useful part is how it scales. The random variation is roughly the square root of the number of photons. A pixel that catches 100 photons has noise of about 10, so the signal is ten times the noise. A pixel that catches 10,000 photons has noise of about 100, so the signal is a hundred times the noise.

More light means a cleaner picture. This is why bigger sensors tend to look better in the dark: a bigger sensor catches more total light from the same scene. It is also why a phone adds a lot of software in low light. It has less light to work with.

Why fast motion can look bent

Most modern sensors are CMOS chips. Each pixel has its own tiny amplifier, and the sensor reads the grid one row at a time. Reading all the rows takes a moment, so the top of the frame is captured slightly earlier than the bottom.

If something moves fast across the frame, like a propeller or a passing car, it shifts between rows, and the shape looks skewed. This is rolling shutter. Sensors that capture every row at the same instant exist. They are called global shutter sensors, and they are harder to build.

What I've simplified

This is the short version. Real sensors add a tiny lens on top of every photosite to funnel more light in. Many move the wiring behind the light-sensitive layer so it does not block anything. Cameras also do a lot of processing after the read, such as noise reduction and sharpening, so the final image is never a pure count.

But the core idea holds. A sensor is millions of buckets catching light, and a photo is the count.