- Panoramic Images: Expanding Scenes with Auto-Align and Auto-Blend
- Seam Carving: Compressing Scenes with Content-Aware Scaling
One of the more popular features in Photoshop is the ability to create a single panoramic image from multiple overlapping photographs. This article will show you how to do that using the improved Auto-Align and Auto-Blend functions. We'll also demonstrate one of the cooler new features in Photoshop CS4—Content Aware Scale. This scaling feature allows you to compress empty areas in your photographs seamlessly, in order to bring two or more subjects in your photograph closer together. Both techniques can be useful when you need to combine or "composite" multiple images using Photoshop CS4.
Panoramic Images: Expanding Scenes with Auto-Align and Auto-Blend
The first step in creating a nice-looking panoramic image is to make sure that you give yourself enough "material" to work with in Photoshop. One of the more common mistakes is to take a series of images with barely overlapping regions, in the hopes that fewer images will be needed for Photoshop to stitch everything together. However, saving a little time on the front end by shooting fewer source pictures rarely pays off. High-quality panoramic images are easiest to achieve in Photoshop when you capture each region of the intended scene with a 20% or 30% overlap relative to the neighboring regions. It may take a bit longer to set up your camera and tripod, and to get all the shots you need, but the quality of the results can make the extra time spent worthwhile.
Once you've processed your raw captures (or JPEGs) and opened the files in Photoshop CS4, you can start the process in one of two ways:
- Create a "file stack" using File > Scripts > Load Files into Stack.
- Shift-drag each image (using the Move tool) onto your base image—usually the leftmost or rightmost shot in the scene—and release.
Both methods produce a stack of layers (each one representing a source image from your scene) inside of a single file (see Figure 1).
Figure 1 Before you can bring all of your images together, you need to stack them as layers inside of a single document.
The next step is pretty straightforward: Highlight all of the source layers in the Layers panel and choose Edit > Auto-Align Layers. This action opens a dialog that gives you different options for aligning all of the images in your stack, end to end (see Figure 2). As you mouse over each option, you'll get a description of what it does. Not sure which option to choose? Auto usually does a pretty accurate job for most subjects, but some experimentation may be necessary.
Figure 2 The Auto-Align Layers function is the first step in blending your source images.
Photoshop CS4 aligns the source layers by using special algorithms that detect the different visual characteristics in the layers. As it finds the parts that are identical from one layer to the next, Photoshop creates the illusion of a single scene. It does this by moving the layers into their respective spots; removing the duplicate areas; and, if necessary, pulling and stretching the layers slightly so that the distortions from your lens are mitigated (see Figure 3).
Figure 3 When the layers are aligned, you may see small hairlines or other imperfections. These are removed by using the Auto-Blend Layers function, which I'll describe in a moment.
After the image layers are laid out and "stitched" together correctly, you may need to zoom out a bit to see the whole image. The amount of data present in this file will exceed the resolution of the original captured images.
The third step in creating a seamless panoramic image is to remove some of the small imperfections that remain from the Auto-Align Layers function. To do this, choose Edit > Auto-Blend Layers. Photoshop opens a dialog that lets you choose the blend method (Panorama was used in this example), and the option to blend tones and colors seamlessly. This feature is particularly useful when you have to account for a continuous gradation in your scene (such as the sky). The result will often be a scene that appears as though it was taken with one camera exposure, plus a few transparent regions around the periphery of the document. Figure 4 shows the Auto-Blend Layers dialog options.
Figure 4 Auto-Blend Layers will attempt to clean up your stitched image, giving it the appearance of a single camera exposure.
All that's left from this point is to do one of two things:
- Crop away the transparent areas and resize the image based on your output specs.
- Bring other visual elements into the scene by dragging layers from other documents or using the File > Place command (my preference, as it creates a Smart Object layer, making the results more flexible).
Figure 5 shows the final, uncropped panorama for this example. Notice the smooth tonal transitions in the sky and the fact that the detailed ground clutter shows no obvious cues that the document was stitched together. This type of result is the reason why the Align and Blend functions in Photoshop are so useful when creating panoramic images.
Figure 5 Final image showing the masked regions of the original layers, with a smooth tonal and color transition across the entire scene.