Here is an equirectangular panorama of a rainbow after a rain storm.
In this blog post I’m going to demonstrate my technique for processing and retouching a panorama created using a Peleng 8mm circular fisheye lens. This panorama was shot handheld without the use of a tripod. This creates a few issues such as stitching artifacts that can be fixed using Photoshop.
In this tutorial I will be using the free program Hugin to create a 360° by 180°panorama. Fisheye lenses make it a lot easier to create an equirectangular image due to their wide field of view.
Creating a panorama in Hugin starts by clicking the load images button.
The Add Images window will appear. You need to select the source images that will be used to create the panorama.
This is the camera and lens data window. In this window you need to define the lens type, the focal length, and the focal length multiplier which is also known as the FOV cropping factor. In this example I’m using a Peleng 8mm circular fisheye lens attached to a Canon DSLR camera with a 1.59 focal length multiplier.
In my experience Hugin does a better job stitching a panorama from fisheye images if you manually define the cropping region. Click on the Crop tab. Next select all of the images listed on the left of the crop window. This will let you define the cropping region for all of the images at once.
Then click in the middle of the frame and drag the circular cropping region. Adjust the cropping region to cut off the color fringed area outside the image area of the circular fisheye photo.
After you have loaded the photos into Hugin and defined the lens type, it is now time to align the images. Click the Align… button to start the alignment process.
Hugin will then start aligning the images. During the alignment stage control points are created that match features in corresponding images.
After the alignment stage completes the fast panorama preview window will open.
If you are interested in creating a 360° by 180° panorama it is important to adjust the cropping area to include the black zone outside the imaged area.
If you want to customize the stitching parameters or output resolution edit the settings in the Stitcher tab found in the main window.
When you are ready to stitch the panorama click the create panorama button found on the main assistant tab. Hugin will then start stitching the image.
Retouching a Panorama in Photoshop
There are multiple ways to retouch a panorama after you finish stitching it in Hugin. One technique is to convert an equirectangular panorama to the cubic format and save out the six cubic faces. Another technique is to use the Polar Coordinate filter in Photoshop to distort the panorama. This will make it easier to retouch the top and bottom of an equirectangular panorama.
In this tutorial I am going to demonstrate the Polar Coordinate filter technique. It has the benefit of staying inside of Photoshop and doesn’t require any 3rd party software.
Once you’ve stitched your panorama in Hugin you may want to perform some retouching in Photoshop to fill in any gaps.
The polar coordinates filter works best with images that are square. So I’m going to resize this image to 5000 pixels by 5000 pixels.
Now that the image is square, we can convert the image from rectangular to polar coordinates. This will make it easier to retouch the poles of the panorama.
From the Filter menu, select Distort, Polar Coordinates…
In the Polar Coordinates window select the Rectangular to Polar option and click okay.
The image has been converted to the polar coordinate projection system. It’s now a lot easier to retouch the sky area with the clone tool or healing brush.
In this screenshot I have patched the hole in the sky area.
Now let’s run the Polar Coordinates filter again and convert the image from Polar to Rectangular coordinates.
Next, let’s rotate the image 180° so we can retouch the bottom of the panorama.
From the Filters menu, select Distort, Polar Coordinates…
Select Rectangular to Polar and click okay.
Now we are ready to start patching the hole in the ground. This view is sometimes called the tiny planet view.
Here I have a photo that I’m going to use as the patch for the NADIR or bottom of the panorama.
I have pasted the ground patch photo into the Photoshop document and I’m going to align and blend it with the background.
An easy way to align the foreground layer with the background photo is to use the difference layer transfer mode.
Add a layer mask to the ground patch layer and use a brush with a soft edge to feather out the border.
Continue to blend the edge of the ground patch with the background using the paintbrush.
Here is the ground patch with the background layer hidden.
In Photoshop from the Edit menu, select Auto-Blend Layers. In this case we want to go with the Panorama Blend Method. This will seamlessly blend the foreground patch with the background.
Your computer will take a moment to calculate the blend.
Next lets use the warp tool to distort the ground patch to better align with the background. From the Edit menu, select Transform, Warp.
The mesh warper makes it easy to bend and stretch the ground patch to line up with the features in the background image. The warp tool is also good at fixing ‘jaggie’ stitching artifacts.
The Liquify tool is also handy for reshaping ground patches. The Liquify tool is located under the filter menu. When using the tool I find it works best with a fairly large brush radius.
Here I have finished retouching the panorama.
Now let’s use the Polar Coordinates filter to convert the image from Polar to Rectangular coordinates.
Let’s orient the image upright by rotating it 180°.
Now let’s resize the image back to 5000 pixels wide by 2500 pixels high.
Here is the completed panorama after some basic retouching.