Home
Tips
Digital
35mm SLRs
Accessories
Medium format
Large format
Camcorders
Gallery
Slide Show
Darkroom
Photo Store
Book Store
Posters Store
Search
Manuals
Contact Us
Links


Note: Photoshop tools and menus are used here as examples which may be different from other image editing programs.  

Correcting Image Distortion

There are several ways to correct distortion in Photoshop. The first place to click-on should be The Lens Correction Filter (Photoshop CS 2) which fixes barrel and pincushion distortion, vignetting, and chromatic aberration. Lets see what each of these problems are and how you can correct them.

  1. Barrel distortion causes straight lines to bow out toward the edges of the image.
  2. Pincushion distortion is the opposite of the barrel distortion effect, where straight lines bend inward.
  3. Vignetting is a defect where the edges, especially the corners, of an image are darker than the center.
  4. Chromatic aberration appears as a color fringe along the edges of objects caused by the lens focusing on different colors of light in different planes.

Defects depend on the lens focal length or the f-stop used. You can set the Lens Correction filter to use settings based on the camera, lens, and focal length used to make the image. You can also use the filter to rotate an image or fix image perspective caused by vertical or horizontal camera tilt. The filter’s image grid makes these adjustments easier and more accurate than using the Transform command.


To correct image perspective and lens flaws:

  1. Choose Filter > Distort > Lens Correction.
  2. Set the grid and image zoom.
  3. Set any of the following options to correct your image.
    1. Remove distortion, correct lens barrel, or pincushion distortion: Move the slider to straighten horizontal and vertical lines that bend either away from or toward the center of the image. You can also use the Remove Distortion tool to make this correction. Drag toward the center of the image to correct for barrel distortion and toward the edge of the image to correct for pincushion distortion. Adjust the Edge option to specify how you want to handle any resulting blank image edges.
    2. Vignette: Corrects images that have darkened edges caused by lens faults or improper lens hood. Amount sets the amount of lightening or darkening along the edges of an image. Midpoint specifies the width of area affected by the Amount slider. Specify a lower number to affect more of the image. Specify a higher number to restrict the effect to the edges of the image.
    3. Chromatic Aberration: Corrects color fringing. Zoom in on the image preview to get a closer view of the fringing as you make the correction.
    4. Fix Red/Cyan Fringe: Compensates for red/cyan color fringing by adjusting the size of the red channel relative to the green channel.
    5. Fix Blue/Yellow Fringe: Compensates for blue/yellow color fringing by adjusting the size of the blue channel relative to the green channel.

    You can also use the filter to rotate an image or fix image perspective caused by vertical or horizontal camera tilt. The filter’s image grid makes these adjustments easier and more accurate than using the Transform command.


    To correct image perspective as seen on the left image, follow the steps above.

Vertical Perspective Corrects image perspective caused by tilting the camera up or down. This makes vertical lines in an image parallel. Horizontal Perspective Corrects image perspective, making horizontal lines parallel. Angle Rotates the image to correct for camera tilt or to make adjustments after correcting perspective. You can also use the Rotate Straighten tool to make this correction. Drag along a line in the image that you want to make vertical or horizontal.
Edge Specifies how to handle the blank areas that result from pincushion, rotation, or perspective corrections. You can fill blank areas with transparency or a color, or you can extend the edge pixels of the image.
Scale Adjusts the image scale up or down. The image pixel dimensions aren’t changed. The main use is to remove blank areas of the image caused by pincushion, rotation, or perspective corrections. Scaling up effectively results in cropping the image and interpolating up to the original pixel dimensions. To use the grid, select Show Grid at the bottom of the dialog box. Use the Size control to adjust the grid spacing and the Color control to change the color of the grid. You can move the grid to line it up with your image using the Move Grid tool.

Transform Tool

Another fast and dirty way of correcting perspective, is the Transform tool. First create a layer . Then choose Edit > Transform > Perspective. Drag the canvas to create a bigger work space. You can then drag one of four corners (or all four) of the transform tool to achieve the results you want.


 

Plug-in Filters for correcting distortion


The Image Factory Perspective is a plug-in for Photoshop and other Photoshop Plug-in compatible software to adjust perspective in images. This plug-in is fast and easy to use, and is my favorite tool for correcting perspective.

Install the filter plug-in to your Photoshop plug-in filters folder. The filter should be available under
filter --> Digital Imaging Tools --> Perspective.


This plug-in shows the results of its calculations in a preview pane (see image above). To better judge the effect of your settings, the preview can be zoomed by the zoom-buttons below the preview pane indicated with a "+" (plus) and "-" (minus) symbol. A percentage of scaling is given between the zoom buttons. You can click the percentage text to quickly switch between 100% and best fit. If the preview is larger than the preview pane you can quickly scroll through the preview by clicking the mouse in the preview pane and subsequently dragging the preview.

The preview checkbox next to the preview pane allows you to switch between previewing the original data and previewing the filtered data. Mac users can use the cmd-space key sequence quickly switch the preview checkbox.

In order for the plug-in to determine the depth of perspective it needs to know what focal length was used when the picture was taken. Select the closest lens type in the popup menu. If you don't know the lens type exactly, then start with "wide angle" as default. If you used a zoom lens with 3x zoom then set the lens type accordingly:

picture taken while fully zoomed out on the subject, use "wide angle"
picture taken while fully zoomed in on the subject, use "tele"

The three orientation sliders allow you to adjust the rotation of the picture in regard to the viewer. Try the sliders separately and you will get an immediate response.

  1. + The "Horizontal" slider brings the left or the right edge of the picture towards you.
  2. + The "Vertical" slider brings the top or bottom towards you.
  3. + The "Rotation" slider rotates the picture.


Because of the rotation of the image relative to the focal point, the image will seem to sheer of the canvas. The advantage of this calculation is an exact fit of several images that need to be stitched. Obviously as much of the picture needs to be preserved. This can be accomplished using the positioning selection. Selecting "Off" simply turns the image as if the camera is moved. Selecting "centered" tries to maintain the midpoint.
The resulting pixels for which no original pixels exist will be black. It is sometimes desirable to have the edge pixels copied in these void pixels, so that retouching at a later stage is made easier.
'Edge Replication" turns copying of edge pixels on or off.

Sampling type
Distorting a digital image requires a technique called re-sampling. Re-sampling helps the computer decide how an arbitrary point in the original image is best represented in the resulting image. The simplest such techniques is called "nearest neighbor" interpolation and consists of simply selecting the pixel closest to the arbitrary point. This is a very quick method but in most cases results in unwanted "aliasing" artifacts, such as jagged edges along supposedly sharp edges.
Another method consists of taking the weighted average of the four pixels closest to the arbitrary point. "Linear" interpolation is an example of this. It is reasonably quick and disguises jagged edges, but also tends to blur the image slightly.
Spline interpolation methods yield even better results. One such method (known as Lanczos interpolation) is implemented using the sixteen pixels closest to the arbitrary point.