How to Lock Pixels but Allow Transforms in GIMP

Locking pixel editing on a background plate while still permitting geometric transformations in GIMP requires configuring GIMP's selective layer locks or utilizing a layer group workflow. GIMP provides independent lock toggles for pixel data and spatial geometry, allowing you to prevent accidental painting, erasing, or filtering while retaining the ability to move, scale, or reposition your layer across the canvas.

Understanding GIMP Layer Locks

Above the layer stack in the Layers dialog (Ctrl + L), GIMP provides multiple lock toggles:

  • Lock pixels (Brush icon): Prevents modification of layer pixels via paint tools (Paintbrush, Pencil, Eraser, Clone, etc.) and color adjustment filters.
  • Lock position and size (Crosshair / Multi-directional arrow icon): Prevents spatial changes made by transform tools, including moving, scaling, rotating, and shearing.
  • Lock alpha channel (Checkerboard icon): Prevents modifications to the transparent areas of the layer.

Method 1: Selective Layer Locking (Move Transformations)

If your geometric transformation only requires moving or repositioning the background plate:

  1. Open the Layers dialog.
  2. Select your background plate layer.
  3. Click the Lock pixels icon (the paintbrush). A highlighted frame will indicate that pixel data is locked.
  4. Ensure the Lock position and size icon remains unselected.

With this configuration, any brush, pencil, or filter applied to the layer will be blocked, but the Move Tool (M) remains functional, allowing you to reposition the layer freely.

Method 2: The Layer Group Workflow (Complex Transformations)

Tools that resample pixels—such as Scale, Rotate, Shear, or the Unified Transform Tool—are categorized by GIMP as pixel-altering operations. If you attempt these transforms with "Lock pixels" enabled, GIMP will produce an error stating that the active layer's pixels are locked.

To bypass this restriction and execute full geometric transforms without risking paint edits on the original plate:

  1. In the Layers dialog, click the Create a new layer group icon at the bottom.
  2. Drag your background plate layer into this newly created layer group.
  3. Select the background plate layer inside the group and enable the Lock pixels icon (paintbrush).
  4. Select the Layer Group folder instead of the individual layer.
  5. Select any transformation tool (Scale, Rotate, Unified Transform, or Perspective).
  6. Apply the transformation to the layer group.

GIMP transforms the container group, recalculating the geometry of all nested contents without requiring the locked plate layer beneath it to accept direct pixel painting.