Ralph Walker's Java Images

My Panoramic Photography Techniques


I am not an expert at this but I know the basics. If you have not made successful panoramic shots before, here is my best advice for taking and editing the photos.

Taking the Photos:

1. The horizon, whether visible or not, must be exactly in the center of the photo. In other words the camera must be level. Don't worry if your subject matter is not positioned vertically where you prefer -- this is how it has to be done.

2. Use a wide-angle lens: If you use a 50mm lens you will probably not have a tall enough angle of view to capture a useful panorama, thus you will probably find yourself using a 35mm or 28mm. However, it is very difficult to 'stitch' together the images if you use a shorter lens, such as a 24mm, due to the barrel distortion. A 360° photo with suitable overlap can be had from six exposures with a 28mm lens, and this is my recommendation. A 50mm lens requires 11 exposures, an unreasonable number. A fixed focal length 28mm lens will work better than a 28-80mm zoon lens because a) it probably really is a 28, b) light falloff at the edges will be more acceptable and c) the fixed lens will be faster, probably by one f-stop. As I will explain below you should avoid the fastest f-stops and this allows you more room.

3. Take your photos left to right. If using a film camera, don't let the photofinisher cut the negatives or mount the slides if you plan to scan them in a film scanner. Plus, you will be able to view and scan the entire panorama correctly on one strip of film.

4. If there are clouds in the shot note how fast they are moving. If they move too quickly they will ruin the shot since the frames won't match up. With the tripod head you may be able to snap off the photos quickly enough to minimize the problem though. This is probably the only place on the WWW where you will read about clouds as a problem in panoramas, but I think it is REALLY important to know.

5. If there are unwanted people in the shot, it is possible to remove them later. (Do as I say, not as I do). Note the gentleman in my 'Luzern' panorama who appears 2 times since he was walking in the direction I was filming. He actually appeared 3 times and I removed him once. I could have waited for him to disappear from each shot but I was trying to be cute. Never snap a frame when a person is close to the edge of it. If there are a number of people or cars passing through the panorama, take more than one exposure of each frame, when the interlopers have moved. Use Photoshop (or other image-editing program) to combine the two images into one pedestrian-and-car-free shot.

6. The light is always brighter on one side of you than another. You must have a camera which allows you to choose your exposure setting in advance and use it throughout the series of photos. Some of these exposures will be darker and some lighter than you would prefer but this is another of those absolutes. You have to do this or you will have ugly, obvious lines between frames.

7. Remember your depth of field. Find the nearest object that you wish to have in focus and make sure you have chosen a combination of f-stop and focus distance (usually infinity) that will allow this object to be sharp. If you have a tripod you can always use a slow shutter speed with small f-stop to do this UNLESS there is activity in the shot that you do not want to be blurred.

If you are using a point-and-shoot camera with exposure-lock you can probably achieve a consistent exposure this way: Choose a frame of the scene which you would like to be your standard, exposure-wise. Note what is in the focus circle in the center so you can return here. Press the shutter release halfway down to lock in that exposure, rotate your body (or your tripod) to compose the desired shot and take it. Return to the first shot to reset the exposure-lock. Don't start this technique (or any panoramic shot) if the sun will go behind a cloud before you can complete the sequence.

8. The sun may have to be included. Usually you avoid including the sun, but it is not a problem if you know how to deal with it. Set your exposure using a frame away from the sun. Your slides or negatives will be properly exposed for our purposes, even though the frame with the sun will be washed-out. If you are using negative film the prints will, of course, be worthless except as a memento, but prints from slides will be OK, as photofinishers do not compensave for exposure when printing from slides. (I know. 99% of folks who are contemplating making panoramas are using a digital camera, as I do, but you might be using film . . . .)

9. If you must scan prints: No matter how much pains you take to get your exposures identical, if you are using print film the photofinisher will print every shot with a different enlarger exposure to try to compensate for your 'improper' exposures. Thus, if you are scanning prints rather than negatives or slides, you have a problem. You can scan the prints and adjust the brightness until they match up. But my suggestion is to use slide film and either scan the film yourself (without using any auto exposure capability of your scanner) or have it scanned into PhotoCD format. (If you have a film scanner you can also scan negatives.) The darker frames in the panorama will look awful on the PhotoCD but don't fret.

Editing the image:

To edit the multiple images into one big one, here is my approach.

Excellent 'stitching' software is available, possibly bundled with your digital camera or scanner, or included with your copy of Photoshop or other Adobe product. If you followed the hints above this software will have no problem stitching the shots together and will do at least as good a job as you can. If you do not have this software, or it can't handle your images, here's the manual drill.

Use Photoshop or another powerful program that will allow you to open and manipulate all the frames at once. Lots of memory will be helpful so give Photoshop permission to use as much as possible (Preferences).

Open all the frames and crop out ONLY the dark borders (in the case of scanned images - doesn't apply to images from digital cameras). Save all frames as LZW Compressed TIFFs and close the files. Do not correct color or otherwise edit these files again. These are your masters in case you want to repeat the process later when you are more skilled.

Re-open COPIES of the two lefthand frame TIFF files. Forget about color-correction, spot removal, etc. at this point. For this example assume you have 6 frames that overlap about 10 percent and that are not perfectly aligned vertically. The negatives were scanned at 300dpi so the files are each 300x450.

Zoom in on the images at the points where they overlap and find the exact columns (using the editor's x-axis counter) where the overlap begins (in frame 1) and ends (in frame 2). Write down these numbers. Assume in this example that overlap begins at column 400 in frame 1 and continues through column 50 of frame 2. (Since the first frame in an image is frame '0' these numbers will be a little confusing.) Your job is to remove the same amount from both frames. In this case remove a total of 50 columns, or 25 from each frame.

There are two reasons to remove equal amounts, barrel distortion and light falloff. Your frames bulge out on all sides, with the distortion worst at the edges. Although you can't remove all of the bulge by removing this small amount of material, you can insure that the two frames have equal distortion, making it easier to 'stitch' them together. And light falloff is worst at the left and right sides, sometimes atrocious, but it is predictable. The frames will mate, exposure-wise, if they are cropped equally.

This is a good time to re-emphasize that you absolutely, positively must have the horizon in the center of the shot. Think of the barrel distortion and the impossibility of stitching tilted images.

Light falloff is caused by lots of factors, but these come to mind: Using any kind of filter, even a skylight filter, will reduce the amount of light falling on the sides of the lens (vignetting). Using a zoom lens at the lower limit of its zoom capability will introduce vignetting. Why? A 28-80 zoom might have excellent optics at 35-75mm, but the manufacturer is naturally tempted to utilize as much range as possible, at the sacrifice of quality at the ends. Using the widest f-stops (f2.8, 3.5 etc.) is to be avoided, for this reason and for others. You will not need the narrowest ones (f16, 22) in any case because you are using a slow film on a tripod, right? Thus, use f5.6-11. If your subject matter is dark, use a slower shutter speed or faster film in order to stay in this range. (For digital cameras you will be using a setting of ISO 100 or lower to minimize grain. Do not use Auto ISO as there is a good chance the camera will choose ISO 200 if your landscape is sunny.)

OK, you've cropped equal amounts from the two files. Save the first, giving it a new name. Close it. Open the third and do the process again. When doing your calculations for the new width of frames 2 and 3, remember that frame 2 is no longer a full 450 pixels wide, only 425. Write all the numbers down as you go.

When you have cropped frames 5 and 6, finish by mating frame 6 with frame 1 (really). Close all files. Don't process these 6 further. They are more backups in case you need to retrace these time-consuming steps later. Trust me on this. It's just disk space and you can erase them after the project is done.

Now it's time to put the 6 frames into one image. Set your background color to something that will contrast well with your subject matter, perhaps white or black or red. Open a COPY of frame 1. Increase it's CANVAS size (not IMAGE size) from 400 pixels to 1000, adding all the new real estate on the right. Add 100 pixels to the top and bottom, giving a file of 1000 by 500. Open a COPY of frame 2 and COPY the entire image to the clipboard. You need to copy every single column so make sure you know how to do this right. Close frame 2. PASTE frame 2 on top of frame 1, zoom in and move frame 2 until it is as well aligned as possible. If you seem to have removed too much on the mating edges, go back and add the needed columns to frame 2, not frame 1 (trust me). Align the two images and FLATTEN the new image, removing the second layer and eliminating the possibility of editing each image individually. Save this file with yet a new name, like "TEMP12.TIF" Add enough columns to the right to hold frame 3 and perform the same process. Keep saving the results with new names, like TEMP123.TIF. Trust me.

When all 6 images have been aligned, crop the top, bottom and right-hand side. Save this and, as before, never touch this file again.

Perform your color correction and save yet another copy.

Do your tedious final editing, removing fuzz and specks, removing as much as possible of the obvious seams, removing offending people and cars. The most valuable tool you have is your CLONE tool. Read all about it. I find that the BLUR tool is nearly useless at this point. Whatever defects you find in your panorama, there is a tool somewhere that will help. This is an excellent learning experience.

When you are done with your correction, save a master copy in TIFF format. You will never erase this, though you may wish to erase everything else, eventually.

You will save copies of this file in various formats and sizes depending on your use. If you intend to view the panorama on your own computer, view the TIFF, which is the best you can get. In our example the file came out to about 250 pixels tall by 2400 pixels wide, which is 600,000 bytes in black and white or 1.8mb in color. Using LZW compression will reduce this somewhat without affecting the content.

If you are going to display this on the Web, export it as JPG with a very low quality level. In Photoshop the quality is designated 0 through 100. All my panoramas above were rendered in quality 0. The busier the subject matter, the less obvious the compression. If your purpose in exporting the file is to use it in a page layout program, you would set the resolution to something that would cause the file to load at the desired size when it was imported. (Someday you may come up with a reason to use a panoramic photo in a document -- maybe you'll make a banner).

If you wish to export a smaller version, reduce the TIFF and export. Never edit a JPG file. Don't even crop or reduce it. Always return to the TIFF. JPGs are 'lossy' (inferior) where TIFFs are 'lossless'. Do not use the GIF format for photos. It is intended for illustrations. It will, technically, work for black and white photos, but the resulting file is as large as a TIFF and not as useful. (Caveat: GIFs can be transparent, and if you need this feature you will sometimes have to use them for photos.)

After you have done a few panoramas yourself you can trash all my hints and use the techniques you will have developed.

I am not a Photoshop expert and don't pretend to be. But you wouldn't have read all this unless you thought I knew more about the subject than you do, so I hope it was worth the time.

Likewise, I know little about Java. I'm just using other people's work. Using David Griffith's Panorama 'class' (applet) I found that I could specify a viewing window of nearly the entire height of the panorama (say 580 instead of 600) and a width of 600. Exceeding these limits caused gray bands to appear or distorted the image. These dimensions may vary depending on your memory, operating system or browser. I am using Windows XP, IE6, 1gb and a Pentium 4.

Return, exhausted, to main page . . .