Apex › Data & encoding
How dithering fakes gray with black & white
How a photo appears on a display that can only draw black or white — e-ink, receipt printers, newsprint. Rounding each pixel to the nearer of black/white bands a gradient into flat blocks and loses all tone. Floyd–Steinberg keeps the tone by spreading each pixel’s rounding error onto its not-yet-drawn neighbours (7/16 right; 3/16, 5/16, 1/16 below), so a patch of two-colour dots averages back to the original gray. Real error-diffusion on a canvas: flip between threshold and dithering, and zoom in to see it’s just two colours.
More in Data & encoding
- Encoding
- How a computer stores a fraction (IEEE-754)
- Why encoders use Gray code (one bit at a time)
- Varint & zigzag
- Base58 & Base58Check
- Line coding
- LZ77 compression
- LZW compression
- Burrows-Wheeler
- How genomes are assembled (de Bruijn graphs)
- Move-to-front
- Content-defined chunking
- rsync (delta sync)
- Finite automata (DFA)
- Huffman coding
- How JPEG compresses an image
- How content-aware resize works (seam carving)
- How video inter-frame compression works
- How MP3 shrinks audio (psychoacoustic masking)
- Why 128 isn’t half-bright (gamma)
- Why RGB blends look muddy (OKLab)
- How HDR fits the sun on your screen (tone-mapping)
- Golomb-Rice coding
- Elias γ/δ coding
- Gorilla (time-series)
- COBS (byte stuffing)
- Arithmetic coding
- CRC-32 walk
- Hamming(7,4) code
- Reed-Solomon
- Viterbi / convolutional
- Error control
- How a barcode works (UPC check digit)
- How a QR code is built (Reed-Solomon + masking)