Play n Tools

Free tools & games for everyone

Free · No sign-up · No accounts

Blend Modes, Curves and Levels: The Maths Behind Photo Editing

· in Learning

Cover picture: Blend Modes, Curves and Levels: The Maths Behind Photo Editing

What multiply, screen and overlay really do, how levels and curves change brightness, and how to read a histogram, explained with simple numbers.

Photo and design programs hide a lot of simple maths behind their sliders. Once you see the numbers, blend modes and tone curves stop feeling like guesswork.

Blend modes are formulas

Every colour channel is a number from 0 (none) to 1 (full). A blend mode combines the bottom layer's value with the top layer's value:

  • Multiply: bottom × top. 0.8 × 0.5 = 0.4, so the result is always darker, and white (1) changes nothing. Good for shadows and line art.
  • Screen: 1 − (1 − bottom) × (1 − top). The opposite of multiply: always lighter, and black changes nothing.
  • Overlay: multiply where the bottom is dark, screen where it is light. It adds contrast, and 50 % grey on top changes nothing.
  • Difference: the gap between the two values. Where two pictures are identical, the result is black.

Opacity and layer masks then mix the blended result with the original: at 60 % opacity you get 0.6 of the blend plus 0.4 of the bottom layer. The Layers & blend modes lab shows these sums channel by channel for any two colours, and lets you blend two layers on a picture, with a gradient or painted mask.

Levels: stretch the range

A photo whose darkest pixel is 12 and brightest is 235 (out of 255) looks flat. Levels with input black 12 and input white 235 stretches that range to the full 0 to 255, so the picture gains contrast. Gamma moves the middle tones: above 1 brightens them, below 1 darkens them, while black and white stay put.

Curves: shape the tones

A curve maps each input brightness to an output. A straight diagonal line changes nothing. Pull the curve up and the picture gets brighter; make a gentle S shape and the shadows get darker and the highlights lighter, which adds contrast. Curves on the red, green or blue channel alone shift the colour, for example to warm up a cold photo.

Fix the colour cast first, then the contrast. White balance changes where the black and white points sit.

Read the scopes, not just the picture

Screens and eyes can mislead you, so editors use scopes:

  1. The histogram counts pixels at each brightness. A tall pile at the far left or right means detail lost to pure black or white.
  2. The waveform shows brightness across the frame, from left to right.
  3. The vectorscope shows colour. Neutral greys sit in the centre, so a cast shows as a cluster pushed to one side.

The Curves, levels & scopes lab has all three beside levels, curves and click-to-pick white balance, on a test picture or your own photo. Your photos never leave your device.

Tags:

All blog posts

See you tomorrow!

A fresh daily puzzle every morning, and new tools added every month.

Browse every product