ELI5: How does a digital camera sensor turn light into a photo?
Whether it's in a phone or a big camera, the sensor does the same basic job: count light, very precisely, in millions of tiny buckets.
Millions of tiny light buckets A sensor is a chip covered in a grid of photosites (often loosely called pixels). When light hits one, it knocks loose electrons. The brighter the light, the more electrons collect during the exposure. At the end, the camera measures how much charge each bucket holds.
But buckets are colour-blind Each photosite only measures brightness, not colour. To capture colour, most sensors put a mosaic of tiny red, green and blue filters on top, usually in a pattern with twice as many green as red or blue (our eyes are most sensitive to green). Each photosite therefore sees just one colour.
Filling in the gaps Software then estimates the full colour at every pixel by looking at its neighbours. This is called demosaicing. After that, the camera adjusts white balance, contrast, sharpening and noise, then compresses the result into a file like JPEG or HEIC.
Why bigger sensors often look better Larger photosites can gather more light, which usually means less grainy "noise" in dim scenes. Phones make up for small sensors with heavy processing, such as combining several quick shots into one.
RAW files A RAW file keeps the sensor's measurements with much less processing, giving more room to edit later.
Do you shoot RAW, or let the camera handle it? What's the most impressive low-light shot your phone has managed?
Comments · 3
The Bayer-style filter mosaic explains a lot about image character. Demosaicing is also why fine repeating patterns, like fabric weave, can show odd colour moire.
A fun way to think of it: each pixel is a bucket catching photons during the exposure. A bigger bucket catches more light, which is why larger sensors do better in dim places.
And the sensor measures only brightness per pixel. The colour comes from those filters plus a good deal of math afterwards. A lot of the photo is computed, not just captured.