Tutorial: using the new mask feature in Hugin
Cristian Marchi says:
As of rev.4978, Thomas Modes added to Hugin the masking feature. That is a very useful function that could save lot of time to panographer and photographer in general. Here I would like to illustarte a way to use POSITIVE masking in the latest version of Hugin.
I also will use Hugin rev5004 compiled under Ubuntu 9.04 (Jaunty).
If you would like to use this feature under Windows, Zoran Zorkic makes available a zip package of Hugin with masking feature at this link.
Let's start.! open up Hugin and a window of the file browser where the images are.
Select the images in the file browser and drag'n drop them in the Hugin Assistant tab.
Press the align button in the same tab and wait for your preferred control point generator to do his work.
When the control point generator has finished the calculation you will be presented with the Hugin fast preview window displaying the images aligned to each others.
Now it's time to create some mask. So head to the mask tab in the Hugin main window and select the first photo of the list on the left. Press now the button marked as add new mask and start adding some points on the image on the right using the left mouse button.
When you have finished adding points use the right mouse button to terminate the process.
As you can see in the left of the mask tab in the main window of Hugin, the mask type is set to "Exclude region and if fact if you look to the preview window you will see that the guy had disappeared.
Now modify the mask type from Exclude region to Include region by using the selector just below the mask type table. You will see now the guy appear in the preview window.
Do the same in all the remaining images by creating a mask that identify the jumping guy and by setting it as "Include region" type
When you have finished take a look at the fast preview window:
Now select the crop tab in the fast preview window and click on the Autocrop button: Hugin will take care of cutting the relevant area of the photo and excluding the black and empty areas
Now go back to the Hugin main window and select the stitcher tab; click on Calculate optimal size (in this way you will get as output the maximum resolution possible for the photo) and finally click on Stitch now!. Select a path to save the output and after Hugin has finished the calculation open a file browser and check the result.
Next is the final image I got using this method:
Thanks to Thomas Modes for this great addition to Hugin!
...and thanks to the guys that did the exhibition in Central Park for being so entertaining!
7:22AM, 20 February 2010 PST
Thanks a TON for this little tutorial. It's great for masking out the little section of panorama head that's visible in the images, and the legs for the nadir shot.
Cristian Marchi says:
Thanks, I'm glad that the tutorial was useful! The masking function it's really a great addition to Hugin.