Sub topic 9
Linking, disabling, inverting and deleting masks
This chapter assumes you can open the Layers and Properties panels, paint on a layer mask with the Brush tool, and make a mask from a selection. Here you will manage masks that already exist. You will move layers without breaking alignment, turn masks on and off, flip them, and decide when to apply or delete them.
The mask thumbnail and the link icon
A layer with a mask shows two thumbnails in the Layers panel: the layer content on the left and the mask on the right. Between them is a small chain icon. That icon is the link.
When the chain is shown, the layer and its mask are linked. They move, scale and transform together. This is the default, and it is what you want most of the time. If you drag a masked layer with the Move tool, the mask travels with it and the revealed area stays in the same place relative to the pixels.
Clicking the chain removes the link. The layer and mask can then move independently. This is useful when you want to slide a photo underneath a mask shape, such as a window or a frame, without moving the shape.
A selection border appears around the thumbnail that is active. Click the layer thumbnail to edit pixels. Click the mask thumbnail to edit the mask. Many "my brush does nothing" problems come from painting on the wrong one.
Linking and unlinking
- Click the chain icon between the thumbnails to unlink.
- Click the layer thumbnail, then use the Move tool to reposition the pixels.
- Click the empty space where the chain was to link again.
Relinking does not realign the two. It only makes them move together from that point onward.
Disabling and enabling a mask
Disabling a mask hides its effect without discarding it. The layer shows in full, as if the mask were not there, but the mask data is kept.
- Shift-click the mask thumbnail. A red X appears across it.
- Or, with the mask selected, click the Disable/Enable Mask button (the eye icon) in the Properties panel.
- Shift-click the thumbnail again to turn the mask back on.
Disabling is a quick before-and-after check. It also helps when you suspect a mask is hiding something you need. Because nothing is removed, you can toggle as often as you like.
This differs from hiding the layer with its eye icon in the Layers panel. The layer eye hides the whole layer, mask included. Disabling the mask hides only the mask's effect.
Inverting a mask
Inverting swaps every value. White becomes black, black becomes white, and a mid-gray of 25 percent becomes 75 percent. What was revealed is now concealed, and the reverse.
To invert:
- Click the mask thumbnail to select it.
- Press Ctrl+I (Windows) or Cmd+I (macOS), or click Invert in the Properties panel.
Common uses:
- You masked the sky and then realized you needed the foreground. Invert instead of repainting.
- You made a selection of the subject but wanted to affect the background. Invert the mask.
- A Hide All mask was meant to be a Reveal All starting point. Invert it.
Be careful which thumbnail is selected. If the layer thumbnail is active when you press Ctrl+I or Cmd+I, Photoshop inverts the pixel colors of the layer, not the mask. That is a destructive change to the layer pixels. Undo it at once with Ctrl+Z or Cmd+Z.
What inversion does to partial values
Because gray means partial opacity, inversion keeps soft edges soft. A feathered transition from white to black becomes a feathered transition from black to white. You do not lose the blend.
The table summarizes the effect of inversion on a few values.
| Mask value | Visibility before | Value after inversion | Visibility after |
|---|---|---|---|
| White (100%) | Fully visible | Black (0%) | Hidden |
| Black (0%) | Hidden | White (100%) | Fully visible |
| Gray (25%) | 25% visible | 75% | 75% visible |
| Gray (50%) | 50% visible | 50% | 50% visible |
Applying a mask
Applying a mask makes it permanent. Photoshop deletes the pixels that the mask hid, and keeps the visible pixels. Partial grays become partial transparency in the layer. The mask is then removed.
To apply:
- Right-click the mask thumbnail.
- Choose Apply Layer Mask.
You can also drag the mask thumbnail to the trash icon and choose Apply in the dialog that appears.
After applying, the hidden pixels are gone from the layer. You cannot paint them back. This returns you to destructive editing, so apply only when you have a reason, such as:
- You need to merge or export a layer with transparency baked in.
- A filter or tool does not work on a layer with a mask.
- You are finishing a file and want to reduce complexity.
If you might want the hidden pixels later, duplicate the layer first or save a version of the file.
Deleting a mask
Deleting a mask removes the mask and leaves the full layer visible, as if the mask had never existed. Hidden pixels return.
To delete:
- Right-click the mask thumbnail.
- Choose Delete Layer Mask.
Alternatively, drag the mask to the trash icon and choose Delete in the dialog.
The difference between applying and deleting is easy to confuse, so compare them directly.
| Action | Hidden pixels | Visible pixels | Mask afterward |
|---|---|---|---|
| Disable | Kept, shown again | Kept | Kept, inactive |
| Apply | Permanently removed | Kept | Gone |
| Delete | Kept, shown again | Kept | Gone |
Moving and copying masks between layers
You can reuse a mask without rebuilding it.
- Drag the mask thumbnail onto another layer to move it. The original layer loses its mask.
- Hold Alt (Windows) or Option (macOS) while dragging to copy it. Both layers keep a mask.
If the target layer already has a mask, Photoshop asks whether to replace it. Copying is useful for applying the same shape to several layers, such as a photo and its drop shadow.
Loading a mask as a selection
Ctrl-click (Windows) or Cmd-click (macOS) the mask thumbnail to load it as a selection. White areas become selected, and grays become partially selected. You can then use that selection to create another mask, an adjustment layer or a fill. Add Shift to add to an existing selection, or Alt/Option to subtract from it.
This is how you share one mask shape across layers without copying the mask itself.
Worked example: repositioning a photo inside a shape
Suppose you have a portrait on a layer, masked to an oval. You like the oval but want the face further left inside it.
- Select the portrait layer and confirm the chain icon is present.
- Click the chain to unlink.
- Click the layer thumbnail, not the mask thumbnail.
- Choose the Move tool and drag the portrait left. The oval stays put.
- Click the chain space to relink.
- Shift-click the mask thumbnail to disable it and check that no important content is cut off outside the oval. Shift-click again to restore it.
Throughout, no pixels were deleted. Because the layer was never changed destructively, you can repeat the process as often as you want.
Common mistakes
- Pressing Ctrl+I or Cmd+I with the layer thumbnail selected, which inverts the image instead of the mask.
- Moving a layer while unlinked and forgetting to relink.
- Applying a mask when disabling would have been enough.
- Deleting a mask and expecting the hidden pixels to stay hidden.
- Painting on the layer thumbnail instead of the mask thumbnail.
Exercise
A masked layer has a mask that hides the left half of a photo. You press Shift-click on the mask thumbnail, and then right-click it and choose Delete Layer Mask. What does the layer look like after each step, and are the hidden pixels still in the file after each step?
Show answer
After the Shift-click, the mask is disabled, so the full photo shows and the mask data is kept. After Delete Layer Mask, the mask is gone and the full photo still shows. In both cases the hidden left half is still in the file, because neither action removes pixels. Only Apply Layer Mask would remove them.
Exercise
You inverted a mask with Ctrl+I, but the photo itself turned into a color negative and the mask did not change. What went wrong, and how do you fix it?
Show answer
The layer thumbnail was selected instead of the mask thumbnail, so Photoshop inverted the layer's pixels. Undo with Ctrl+Z (Cmd+Z on macOS), click the mask thumbnail so its border is highlighted, and press Ctrl+I (Cmd+I) again, or use Invert in the Properties panel with the mask selected.
Exercise
You want the same oval mask on both a photo layer and a separate texture layer, but you also want to keep the original mask on the photo. How do you do it?
Show answer
Hold Alt (Windows) or Option (macOS) and drag the mask thumbnail from the photo layer onto the texture layer. This copies the mask. Without the modifier key, the mask would move and the photo layer would lose it.