How stitching works

From PanoTools.org Wiki
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

Introduction

Stitching is about making one large image from several smaller photos. The ambition is to have the fact of individual ingredient photos no longer show through in the resulting image. This page shows what stitching software actually does.

If you want to know how to achieve this, or what software to use, please read a tutorial instead. What can be done and what quality can be achieved, this shall be demonstrated step by step starting with the two photos below.

Img08232.jpg Img08231.jpg

At the time of photography, some guidelines have been followed that make the photos good stitching material.


For comparison to stitching proper, the two photos have simply been overlayed in a standard image editing and retouching software.

Img0823xoverlay1.jpg Img0823xoverlay2.jpg

Please notice in particular the misalignment of geometrical features in the left image, and the roof misorientation in the right one.


Have a look at the following aspects to see where proper stitching software can do better. Such software usually gives a choice of either performing these steps fully automatically, or provide assistance for optimisations without requiring a try-and-error workflow.

Remapping

Img08232remap.jpg Img08231remap.jpg

To project the images onto the same virtual screen, they need to be remapped, as shown above. Correcting falling lines as in this example is by choosing an appropriate orientation for the virtual screen.

Img0823xstitch3.jpg

The relative camera orientation, and the lense parameters are determined from the images overlap area. Handheld photos are fine. If the photos have been taken from the same point, expect alignment accuracy of better than a pixel.

Exposure

Img0823xstitch4.jpg

Input images need not have the same exposure, or white balance. Together with vignetting (images are darker in the corners than in the middle) the required corrections can be derived from images with a suitably large overlap area.

Blending

Obviously, there needs to be some kind of seam between the images, but one can do better than a hard seam line (used above) or a feathered transition that affects the image character.

Img0823xstitch5.jpg

State of the art is a seam mechanism that behaves like a line for small details but averages for large scale features.

Img0823xstitch6.jpg

In addition, the seam line should be placed intelligently to avoid cutting through objects (like cloud, car or bicycle) that have moved in the time between taking the images.

Overall Result

Img0823xstitch6crop.jpg

This is the overall result, cropped to rectangular shape, for a state-of-the-art stitching of two photos.