Home / Articles / Adobe Photoshop / Using the Clone Stamp Tool and the Lens Correction Filter in Photoshop CS4

Using the Clone Stamp Tool and the Lens Correction Filter in Photoshop CS4


  1. The Clone Stamp Tool
  2. Lens Correction

Article Description

The Clone Stamp tool lets you copy pixels from anyplace in your image (or even another image) and then paint them some where else. This excerpt shows you how to use the Clone Stamp tool and Lens Correction filter in Photoshop CS4.

The Clone Stamp Tool

The Clone Stamp tool lets you copy pixels from anyplace in your image (or even another image) and then paint them some where else. It works much like the Healing Brush we covered earlier: Option-click (Mac OS X) or Alt-click (Windows) to pick up a source point, and then paint away elsewhere to copy those pixels. The difference is that while the Healing Brush automatically tries to blend the source and destinations, the Clone Stamp just paints the source literally. This requires more manual touch-up—which is why the newer Healing Brush is often better for this kind of work.

Keep Jumping Around. The single biggest mistake people make with the Clone Stamp tool is dragging the mouse in a painting fashion. That tends to create repeating patterns, making the retouch more obvious (see Figure 11-10). Instead, dab here and there with a number of clicks.

Figure 11-10 Avoid repeating patterns by changing the source point.

One exception to this rule is when the area you’re cloning is relatively flat and has little texture or detail (such as the blurry background behind a portrait). The second exception we make is when we’re using the Clone Stamp tool with a blending mode such as Darken, Lighten, or Soft Light—and then only when the effect is subtle and doesn’t create an obvious clone.

A second mistake people make is continuing to clone from the same area. Keep changing the source point that you’re cloning (the point on which you Option/Alt-click). For example, if you’re erasing some specks of dust on someone’s face, don’t just clone from one side of the specks. Erase one speck from pixel information to the left; erase the second speck from the right, and so on.

There are times, of course, when both of these pieces of advice should be chucked out the window. For example, if you’re rebuilding a straight line by cloning another parallel line in the image, you’d be hard-pressed to clone it by any other method than painting in the whole line. The following tip provides a way to do so relatively painlessly.

Stroking Paths. Back in Figure 11-7 we showed how to get rid of straight scratches by Shift-clicking with the Spot Healing Brush. But what if you want to remove a line that isn’t straight, such as power lines, which are always more noticeable in a photograph than they were in reality? For that, you can use the Pen tool to draw a path, then use the Clone Stamp tool to stroke the path, obliterating the offending pixels in one fell swoop (see Figure 11-11).

  1. Draw the path using the Pen tool, keeping it as close to the center of the power line (or other defect) as possible. It’s a good idea to save the path (double-click on Work Path in the Paths panel and name it).
  2. Select the Clone Stamp tool and click the Aligned button in the Options bar. To remove a light-colored scratch, set the mode to Darken; to remove a dark power line, set the mode to Lighten.
  3. Choose a soft brush a little wider than the widest point of the scratch.
  4. Option-click (Mac OS X) or Alt-click (Windows) beside the start of the path to set the source point for the cloning operation, just as you would if you were going to clone-stamp the scratch by hand.
  5. Shift-click on the path in the Paths panel to hide it, then drag the path over the Stroke Path with Brush button at the bottom of the panel (see Figure 11-11). The power line is gone! It works because stroking a path always uses the current tool as the brush (in this case, the Clone Stamp).

Figure 11-11 Removing power lines with a path and the Clone Stamp tool

Using the Clone Source Panel

If you often wish you had a little help picking perfectly aligned source points with the Clone Stamp or Healing Brush tool, that help is available in the form of the Clone Source panel (see Figure 11-12). It helps you position and angle the source point precisely, before you start cloning. On top of that, the Clone Source panel can remember up to five source points, so that if you have to go back and redo or refine a previous area, you don’t have to tediously reestablish where it was. These features save so much time that you’ll never want to clone without the Clone Source panel by your side.


Figure 11-12 The Clone Source panel

Open the Clone Source panel by choosing Window > Clone Source, or click the Clone Source icon in the dock, if it’s visible.

Setting Multiple Clone Sources. The five icons across the top of the Clone Source panel represent the five source points you can save. The selected Clone Source button is the one that remembers where you’ve Option-clicked/Alt-clicked, so if you want the Clone Source panel to remember a different source point, select a different Clone Source button first. Of course, all you have to do to switch to a different clone source is to click the Clone Source button you used to save it—kind of like saving and recalling radio stations using the radio buttons on a car stereo. Keep in mind that a clone source can be in a different open document, so your five saved clone sources can come from various open documents.

Setting the Clone Source Offset. Use the Offset section of the Clone Source panel to make the clone source do your bidding. The X and Y fields report the current distance of the cursor from where you Option-clicked/Alt-clicked the clone source; you can enter values here (to change the unit of measure, right-click, or Control-click in Mac OS X). The W and H fields control the scaling percentage of the width and height of the clone source, respectively, and the angle field lets you rotate the clone source in degrees.

Using the Preview Overlay. The very useful preview overlay shows you where the cloned pixels will land when you click or drag. To show it, turn on the Show Overlay check box in the Clone Source panel. When you do this, you’ll see a semitransparent copy of the image that moves with the cursor (see Figure 11-13), telling you where you’ll be painting the cloned source pixels when you click or drag. As soon as you click or drag, the overlay goes away, because you’ve positioned it. (If the Auto-Hide check box is on, the overlay remains visible as you paint.) If you Option-click/Alt-click a new source point, the overlay appears again until you click or drag to set the new source. If you chose to leave Show Overlay off, you can press Option-Shift (Mac OS X) or Alt-Shift (Windows) to display the overlay.


Figure 11-13 The clone source preview overlay with the Clipped check box off

By default, the preview overlay is the size of the brush tip. If you’re using a small brush tip, the overlay might be difficult to see. To make an overlay as large as the layer, turn off the Clipped check box in the Clone Source panel; if you used Photoshop CS3 you’ll recognize that the layer-sized preview overlay is the way it worked by default in CS3. The Clipped check box in the Clone Source panel is called Clip to Brush tip in the panel menu.

If you don’t quite manage to align the overlay correctly the first time, there’s no need to start over. Just Option-Shift-drag (Mac OS X) or Alt-Shift-drag (Windows) to reposition the overlay; the overlay will be visible only when you drag. To numerically position, scale, or rotate the overlay, enter values into the Offset section of the Clone Source panel. To reflect the clone you’re painting, click the link icon to turn it off, and enter a negative value into the W or H field. An undistorted reflection is represented by –100 percent.

Removing Red-Eye

A common retouching task is removing red-eye—that devilish effect that appears when a camera flash reflects off the retina. Ideally, you’ll avoid red-eye by using off-camera flash, but if your (or someone else’s) photograph already has red-eye, you’ll have to remove the red. The Red-Eye tool (sharing a slot on the Tools panel with the healing brushes and the Patch tool) is by far the easiest way of doing so, but sometimes it removes the eye color too, so we still resort to the following techniques when necessary.

Hue/Saturation. Select the offending pupils with an oval marquee, feather the selection by a few pixels, copy the selection to a new layer (Command-J in Mac OS X, Ctrl-J in Windows), and then use Hue/Saturation to shift the color, brightness, and saturation. Every image requires different values, but we usually start with Hue at +40 (for brown eyes) or –120 (for blue eyes), Saturation at –75, and a Lightness value of –50. The key is to remove the glaring color while still maintaining the specular highlights and color that make the eye look alive.

Color Replacement Tool. The Color Replacement tool lets you change the color of pixels to the foreground color but leave the pixels’ saturation and brightness alone. In other words, it changes the color but retains the detail. We haven’t found it useful for large areas, but it’s quite good at fixing things like red-eye. Hold down the Option key (Mac OS X) or Alt key (Windows) and click on the darkest part of the eye (or some other dark area nearby), then let go of the Option/Alt key, adjust the brush size to slightly smaller than the pupil, and draw over the red portions. You may need to increase the Tolerance level in the Options bar to 35 or 40 percent.

Perspective Retouching

The Vanishing Point filter makes editing in perspective orders of magnitude easier than it used to be. Vanishing Point is a very deep plug-in, and if you plan to use it a lot, we strongly recommend reading about the filter in the online Photoshop Help file and mastering the considerable number of options and keyboard shortcuts.

Defining the Planes. To open Vanishing Point, choose Filter > Vanishing Point, or press Command-Option-V (Mac OS X) or Ctrl-Alt-V (Windows). The first step in using Vanishing Point is to define a perspective plane by clicking on four points, and then to enlarge the plane to cover the area you want to affect (see Figure 11-14). Watch the color and size of the grid when dragging its corners or sides: Red means the grid is not valid perspective, yellow is pretty close, and blue is good. In general, it’s better to see a grid of bigger squares than smaller rectangles. Sometimes moving the grid corners by a pixel or two will make a big difference in the quality of the perspective.


Figure 11-14 Cloning in perspective in the Vanishing Point filter

Performing the Cloning. Once you’ve defined the plane, you can use the Marquee or Clone Stamp tool to clone regions in the image or paste elements from other images. In Vanishing Point, a selection you drag using the marquee automatically conforms to the perspective plane. In this simple example, we used the marquee to select a building that was still standing, then Option/Alt-dragged it to duplicate it, replacing a demolished building.

In this simple example, we used a single perspective plane. Once you’ve defined the basic plane, you can create additional hinged planes by Command-dragging (Mac OS X) or Ctrl-dragging (Windows) a side (not corner) handle on the edge of a plane. You can adjust a hinged plane’s angle by Option-dragging (Mac OS X) or Alt-dragging (Windows) one of its side handles or by editing the Angle field at the top of the Vanishing Point dialog. And while we generally find that it’s easier to fine-tune the result on a layer after we’ve run Vanishing Point, the Transform tool in Vanishing Point lets you transform floating selections.

For more complex cloning operations, we use Vanishing Point’s Stamp tool, which works just like the Clone Stamp tool. We could have achieved the result shown in Figure 11-14 by using the Clone Stamp tool instead of the technique demonstrated in the figure.

2. Lens Correction | Next Section