Stitching handheld panoramas with Panorama Tools - pt2 (pt1)
In the first part of this tutorial before we cropped it to make a panorama suitable for conversion to QTVR we had produced a 180 by 360 degree PSphere panorama. It looked like this:

It was 1530 pixels high and 3060 pixels wide ie. like all fullview PSphere images it has proportions 1:2. Note that there are blank areas at the top and bottom of the image corresponding to scene detail not incorporated yet. To provide this missing detail we have to incorporate the up and down shots of the photography sequence. These up and down shots, like the main horizontal sequence of shots, were here taken with the same lens - a 16mm full frame Nikkor fisheye.

These images look like this - cropped to our standard size of 1296 pixels high by 1926 pixels wide:

We correct these images into ideal fullframe fisheye form with application of the Correct tool using the same settings as before giving us these three slightly different images:

Consider this last "up" shot - the "corrected" one. It is a fullframe fisheye shot 136 degrees wide. To insert this image into our PSphere panorama we need to follow a two-step process. First we "extract" a view from the panorama which corresponds as best possible with the existing (corrected) up shot we have here.Then we complete the missing areas in this extracted view with detail from our (corrected)up shot and then re"insert" the retouched extracted view into our panorama. This "Extracting" and "Inserting"can be done with the Adjust tool in Panorama Tools:

Click Adjust

We see a window entitled "Create Panorama" .... this is a little misleading here as we are not actually creating a panorama - we are extracting a view from a panorama. Anyway, here we must check "Extract" and "Use options". Uncheck others if necessary. "Prefs" as before and "More" as before. So click "Set" to open the "Options" window.

At the top of the "Options" window we have fields where we can enter details of the view we want to Extract. In this case we want it to match our (corrected)up shot so we want to make it a Fullframe fisheye image which is 136 degrees wide and 1296 pixels high and 1926 pixels wide. So we fill in those values for the "Image" section ie. set HFOV=136, width=1926, height=1296, set format to FisheyeFF. The image we want is a view corresponding to a virtual camera looking straight up so we set Pitch to 90 and Yaw and Roll to 0.

In the next section "Panorama" we fill in the values for the PSphere panorama we are working with - thus HFOV =360 width=3060 and height=1530and we set the format to PSphere.

Next we check "Save to buffer". We are going to apply the Adjust tool to the PSphere panorama in order to "extract" the full frame fisheye view we specifed in the "Image" section. What checking "Save to buffer" does is save this source panorama in a temporary location on the hard disc. The view that is extracted can be modified then reinserted in the same location in the original image - this reinsertion will only work if the original image is available to the tool in the temporary storage location - the buffer. Since this is what we want to do with the extracted view we check the "Save to buffer" item.

In the next section "Stitching" we uncheck "Load buffer" if necessary. Settings on the other items will have no effect with an extract operation.

So now we can click OK and we get this:

Compare the (corrected) up shot

To make the views correspond better it is apparent that "yaw" must be adjusted in the values which specify the extracted up view. So in the Options setting in Adjust/Extract we try a couple of different Yaw values. One or two trial Yaw settings will produce an extracted view which corresponds better with our existing up view. In this case a value of 120 (rotating the virtual "up" camera a 120 degrees) in the Yaw field yields an extracted view that looks like this :

This is obviously a lot closer to the (corrected) up shot
The task is to fill in the hole in the extracted image from the PSphere panorama. We use the detail from the (corrected) up view - the image on the right above. Because there is some much fine detail in these branches this is not a trivial task in this case. Often the missing up circle will just be clouds or sky and very easy to fill in - here a single cut and paste operation will not work. It was necessary to select small irregular areas and fill in the hole in half a dozen steps gradually filling in the hole from above. Considerable use of the Transform tools was necessary. With the hole completed the extracted view now looks like this:

Now we want to reinsert this retouched extracted view into our original PSphere panorama. Again we use the Adjust tool but with slightly different settings in the Options settings. So to do this reinsertion do this:

Go Panorama Tools

Select Adjust

In the Create Panorama window change the settings so that now "Insert" is checked. "Use Options" is still checked. "Prefs" and "More" as before. Now hit "Set" and modify the options so that now "Save to buffer" is unchecked and "load buffer" is checked. Otherwise leave the "image" and "panorama" settings as before. So now Panorama Tools will take the "image" - the retouched extracted view and paste it exactly where it came from in the original panorama (which is accessed from the "buffer"). Click OK and the new panorama with the "inserted" retouched "up" extract image looks like this:

A similar process with extracting a "down" view and retouching it with detail from the (corrected) down shots and then reinserting it into the panorama will produced an image that looks like this:

This is in fact the finished panorama and can be used as is to make a full 180 degree up and down Zoomit vr scene with Live Picture's Photovista.. But at 1530 by 3060 pixels it is too large for the web so we resize it to 1200 by 2400 pixels and change the JPEG compression to Low. This produces this Zoomit panoramic scene.

If we want to make a QTVR from this fullview image then it has to be cropped vertically first. So returning to our full size PSphere panorama crop it with the Canvas Tool so it is say 157 degrees high. This means cropping it to a height of 157/180 times 1530 pixels ie. 1335 pixels high so it looks like this

To convert this to (cylindrical) perspective requires the use of the Remap tool in Panorama Tools. So go:

Remap

Set "Convert from" to "PSphere"

Set "Convert to" to "QTVR-Panoramic"

Set HFOV to 360 and VFOV to 157

This produces an image which is 3060 pixels wide and 4800 pixels high - too big for a web QTVR so we resize it to 1800 pixels wide and 2824 pixels high. Keeping in mind the divisible by 24 requirement we use Canvas size to reduce the height to 2784 giving us this 1800 pixels wide by 2784 pixels high 156 degrees VFOV cylindrical panorama:

This produces this QTVR scene and again the Zoomit version is here

Copyright : Peter Murphy 1999