How can I correct converging verticals in software without a tilt-shift lens?

Asked 1/1/2018

5 views

2 answers

0

I want to photograph buildings so the vertical lines stay parallel instead of converging. I understand this is usually done with a shift lens, but I use a Fujifilm X100 with a fixed lens. I’m not asking about the “miniature” tilt effect or shallow depth of field—just geometric perspective correction for architecture.

Can this be done reliably in software, and what transformation is involved? Is it basically mapping a trapezoid back to a rectangle, or is the geometry more complex? I use GIMP and Inkscape, and I’m also interested in the underlying geometric principle.

Originally by Photography Stack Exchange contributor. Source · Licensed CC BY-SA 4.0

Photography Stack Exchange contributor

8y ago

2 Answers

4

Although many lenses that have the ability to control one also have the ability to control the other, tilt and shift are two different movements.

The "miniature" look is achieved using tilt movements. The optical axis of the lens is tilted away from a perpendicular angle with respect to the imaging plane.

tilt movement

Correcting perspective in terms of converging lines is accomplished optically using the shift movement. The 90° angle of the lens' optical axis with respect to the imaging plane is maintained. The center of the lens' optical axis is moved away from the center of the film or sensor while remaining perpendicular to the plane occupied by the film/sensor.

shift movement

Assuming the building is perpendicular to the ground, this has the same effect as pointing the lens' optical axis horizontally and then cropping away all but the top part of the image. Shift lenses have larger image circles than the formats they are designed to be used with, so the field of view can be shifted fairly far to one side or another of the image circle cast by the lens and we don't have to give up resolution by cropping a significant portion of the image.

enter image description here

It is possible to tilt the camera up at the building and correct for the converging lines using software. Of course, any time we start remapping pixels we give up a small but measurable amount of resolution.

Is this as simple as projecting a rectangular image onto a trapezoid? Just squashing the bottom edge of the rectangle? Or is it more involved than this? Is the projected shape more complex that a trapezoid perhaps?

It depends upon the characteristics of the lens you are using and whether or not the camera provides lens distortion correction. If your lens has any significant geometric distortion, you'll need to correct for that before doing your trapezoidal projection to correct for the perspective "distortion" caused by your shooting position. Be careful, though. If your camera already does geometric distortion correction automatically you don't need to apply it again.

Originally by user15871. Source · Licensed CC BY-SA 4.0

user15871

8y ago

0

AI Answer

Generated from our catalog & community — verify before relying on it.

Yes. For converging verticals, you want perspective/keystone correction, which corresponds to the effect of a shift movement, not tilt. Tilt is what creates the selective-focus “miniature” look; shift is what keeps architectural lines parallel.

In software, this is typically done with a perspective transform: effectively remapping the building from a trapezoid back to a rectangle. Tools like GIMP’s Perspective tool can do this, and Darktable also offers keystone correction and lens-distortion correction.

A few practical limits:

  • You lose some effective resolution because the image must be resampled/interpolated.
  • You still need the whole subject in focus in the original capture.
  • Strong corrections may require cropping and can reveal lens distortion, so correcting lens distortion first can help.

So the basic idea is straightforward: keep the camera as level as possible when shooting, include enough extra space around the building, then use perspective/keystone correction in software to straighten the verticals.

UniqueBot

AI

8y ago

Your Answer