Sub topic 1
Why adjust non-destructively
Every tonal or color change in Photoshop does one of two things. It either rewrites the pixels in the layer, or it records a set of instructions that Photoshop applies on top of the pixels. This chapter explains the difference, why it matters, and where the non-destructive approach has limits. Later chapters cover the specific adjustments (Levels, Curves, Hue/Saturation) and the masks that control them.
Prerequisites
This chapter assumes you can already do the following:
- Navigate the Photoshop interface: open and save files, find panels, and select tools.
- Use the Layers panel to add, hide, reorder, and rename layers.
- Describe RGB color at a basic level: each pixel has red, green, and blue values, and brightness depends on those values.
- Use sliders and numeric fields.
You do not need to know Levels, Curves, or masks yet. Each gets its own chapter.
What "destructive" means
A destructive edit changes the stored pixel values and keeps no record of the old ones. If you choose Image > Adjustments > Levels while a pixel layer is active, Photoshop computes a new value for every pixel and writes it into that layer. The original values are gone, except through Undo or the History panel.
Three things make this a problem in practice:
- Undo is short-lived. The History panel holds a limited number of states, and it is cleared when you close the document. A change you notice three days later cannot be undone.
- Edits compound. Each adjustment works on the result of the last one. Suppose you brighten an image, then darken it. The result is not the original, because the first step may have clipped values (pushed them to pure black or white), and clipped values cannot be recovered.
- You cannot revisit one decision. If you made five adjustments and the second was too strong, you cannot change it without discarding the three after it.
A non-destructive edit avoids all three by keeping the adjustment's settings separate from the pixels.
How an adjustment layer works
An adjustment layer is a layer that holds settings instead of pixels. A Levels adjustment layer stores values such as the black point, white point, and midtone slider position. Photoshop applies those settings to everything below the adjustment layer in the stack, and it does so each time it draws the image.
The pixel layers underneath are never modified. Consequences:
- You can reopen the adjustment at any time and change its values. The new result is computed from the original pixels, not from a previous result.
- You can hide it with the eye icon to compare before and after.
- You can lower its Opacity to reduce its strength, or delete it to remove it entirely.
- You can restrict it to part of the image with a layer mask, which the later chapters on masks cover.
The model in code
Both Levels and Curves are functions that map an input value to an output value. The functions below model the idea, not Photoshop's exact internals. This one models Levels on a single 8-bit channel (values 0 to 255):
def levels(value, in_black=0, in_white=255, gamma=1.0, out_black=0, out_white=255):
"""Map one 8-bit channel value the way a Levels adjustment does."""
t = (value - in_black) / (in_white - in_black)
t = min(max(t, 0.0), 1.0) # clip below the black point and above the white point
t = t ** (1.0 / gamma) # gamma > 1 brightens midtones, gamma < 1 darkens them
return round(out_black + t * (out_white - out_black))A destructive edit calls this function once and stores the output in place of the input. An adjustment layer stores only the arguments (in_black, in_white, gamma, and so on) and calls the function again whenever the image is displayed. The sketch below shows the difference:
def levels(value, in_black=0, in_white=255, gamma=1.0, out_black=0, out_white=255):
t = (value - in_black) / (in_white - in_black)
t = min(max(t, 0.0), 1.0)
t = t ** (1.0 / gamma)
return round(out_black + t * (out_white - out_black))
original = [10, 40, 128, 220, 250]
# Destructive: the stored pixels are replaced by the result.
destructive = [levels(v, in_black=30, in_white=230) for v in original]
# Non-destructive: the pixels stay, and only the settings are stored.
settings = {"in_black": 30, "in_white": 230}
displayed = [levels(v, **settings) for v in original]
print("original: ", original)
print("destructive:", destructive)
print("displayed: ", displayed)
# Change your mind: edit the settings, and the result comes from the original again.
settings["in_black"] = 10
displayed = [levels(v, **settings) for v in original]
print("revised: ", displayed)The first line printed is original: [10, 40, 128, 220, 250]. The values 10 and 250 fall outside the 30 to 230 range, so they clip to 0 and 255. In the destructive list, those clipped pixels have lost their original values for good. In the non-destructive version, original is untouched, so changing in_black to 10 brings back a value of 0 for the first pixel by a different calculation, and the second pixel changes from 10 to 33 instead of being stuck at the earlier result.
The comparison is the whole argument for this chapter in miniature: the stored data stays the same, and only the small settings dictionary changes.
The stack and the order of evaluation
Photoshop evaluates the Layers panel from the bottom up. An adjustment layer affects every layer below it, up to the bottom of the stack, unless you clip it to a single layer (a later chapter).
Order matters because the adjustments do not commute in general. Applying Curves before Levels can give a different result from applying Levels before Curves, because the second adjustment receives the first one's output. The chapter on stacking order covers this in detail.
Creating one: the short version
The next chapter covers the Properties panel in full. For now, two routes create an adjustment layer:
- Click the half-filled circle icon at the bottom of the Layers panel and choose an adjustment, such as Levels.
- Choose Layer > New Adjustment Layer and pick one from the submenu.
Do not use Image > Adjustments if you want the non-destructive behavior. That menu applies the change directly to the active pixel layer. This is the most common mistake for people who learned Photoshop from older tutorials.
Other non-destructive techniques
Adjustment layers are one of several ways to avoid altering pixels. They sit alongside these:
| Technique | What it keeps intact | What it is used for |
|---|---|---|
| Adjustment layer | Pixel layers below | Tonal and color changes |
| Smart Object with Smart Filters | The original embedded image | Filters such as blur and sharpen, and repeatable transforms |
| Layer mask | The masked pixels (hidden, not deleted) | Hiding parts of a layer or adjustment |
| Duplicate layer | A backup copy | A quick safety copy before pixel painting or retouching |
Adjustment layers handle global tonal and color work. They do not replace the others. Retouching with the Clone Stamp, for example, still needs a pixel layer, so you would paint on a new empty layer with "Sample: Current & Below" rather than on the photo itself.
Costs and limits
The non-destructive approach is not free. Know these trade-offs before relying on it:
- File size. Adjustment layers are small, but a PSD or PSB with many pixel layers and masks grows quickly. Saving the layered file as well as a flattened export is normal practice.
- Compatibility. Layers survive only in formats that support them, such as PSD, PSB, and layered TIFF. Saving as JPEG flattens the image, which bakes every adjustment into the pixels. Keep the layered master and export JPEG copies from it.
- Not everything is adjustable. Some operations have no adjustment layer, such as most filters, resizing, and cropping with "Delete Cropped Pixels" turned on. Use Smart Objects and non-destructive crop settings for those.
- Bit depth still matters. A non-destructive stack does not give back detail that was already lost. An image captured at 8 bits per channel has only 256 levels per channel, so strong adjustments can still produce banding (visible steps in smooth gradients). Working in 16-bit mode, when your source allows it, gives the adjustments more room.
- Clipping at capture is permanent. If the camera recorded pure white with no detail, no adjustment layer can restore that detail.
A habit to build now
Adopt these habits from the start, because the rest of the tutorial assumes them:
- Open the photo and leave the background layer alone.
- Make every tonal or color change with an adjustment layer.
- Name each adjustment layer for what it does, for example "Lift shadows" or "Warm skin", so a long stack stays readable.
- Save a layered master (PSD) and export flattened copies separately.
Exercise
You apply Image > Adjustments > Levels to your photo layer and save as a PSD. A week later, the highlights look too bright. Why can you not simply reopen the Levels settings, and what should you have done instead?
Show answer
Image > Adjustments rewrote the pixel values in the layer and stored no settings, so there is nothing to reopen. Values pushed to pure white were clipped and cannot be recovered from the file. You should have used Layer > New Adjustment Layer > Levels (or the half-filled circle icon in the Layers panel), which stores the settings in a separate layer and leaves the original pixels untouched.
Exercise
In the code example, the settings dictionary has inblack set to 30 and inwhite set to 230. A pixel has the value 250. What does levels() return for it, and why does the stored original value of 250 still matter?
Show answer
It returns 255, because 250 is above the white point of 230, so t is clipped to 1.0. The original 250 still matters because the non-destructive approach keeps it in the pixel layer. If you later raise in_white to 255, the same pixel is recomputed from 250 and returns 250 rather than staying at 255.