which part of hugin removes the fish eye distorsion when creating a 360 panorama?

126 views
Skip to first unread message

Forex Valdes

unread,
May 29, 2015, 4:45:57 PM5/29/15
to hugi...@googlegroups.com
HI all
I am trying to understand the stitching process to do the stitching using a commmand line or to integrate it into my reaserch project. So far in hugin I get the right output. I have 6 pictures from gopro that has a fish eye lense. At the end the panorama looks fine - in my input photos lines are not straight due to fish eye but in the output the lines are straight which is good
My doubts are which part in the command line removes the fish eye distorsion? is it nona?
I do not understand how distorsion and control points work. If I set my control points before I remove the fisheye distorsion, aren't the control points affected because they were calculated in the original image and not on the defished one? also to remove distorsion you need to crop the image a bit. wouldn't this remove some control points?
Thanks for all help - I am realy confussed.

Terry Duell

unread,
May 29, 2015, 7:01:43 PM5/29/15
to hugi...@googlegroups.com
Hello Forex Valdes,

On Sat, 30 May 2015 05:33:01 +1000, Forex Valdes <cvald...@gmail.com>
wrote:

> HI all
> I am trying to understand the stitching process to do the stitching
> using a
> commmand line or to integrate it into my reaserch project. So far in
> hugin
> I get the right output. I have 6 pictures from gopro that has a fish eye
> lense. At the end the panorama looks fine - in my input photos lines are
> not straight due to fish eye but in the output the lines are straight
> which is good
> My doubts are which part in the command line removes the fish eye
> distorsion? is it nona?

The look (or distortion) in your output panorama depends on your output
projection.
To get a feel for this, after alignment, play around with the projection
in the Fast Panorama preview window.

> I do not understand how distorsion and control points work. If I set my
> control points before I remove the fisheye distorsion, aren't the control
> points affected because they were calculated in the original image and
> not on the defished one? also to remove distorsion you need to crop the
> image a bit. wouldn't this remove some control points?
> Thanks for all help - I am realy confussed.

The control points define identical locations in overlapping areas of
images, thus enabling the images to be aligned.
Defishing is essentially just changing the projection of an image.
Alignment is done using the defined control points, and a defined crop
area is applied after alignment and only affects the output panorama.
To set your output projection using a script or command line tools, you
could do this using 'pano_modify'.

Hope that helps, and that I haven't misunderstood your problem.

Cheers,
--
Regards,
Terry Duell

Forex Valdes

unread,
Jun 8, 2015, 10:43:37 AM6/8/15
to hugi...@googlegroups.com
Thanks Terry
Let me see if I got it right. I am using equirectangular.
I was thinking that you need to remove distorsion before you project to equirectangular so the images to be projected have straight lines and not curved, and no fish eye effect. But you say you project to equirectangular and the projection will help to remove the fisheye effect? or you do two steps in one projecting and removing distorsion?
If I see my original pictures they show distorsion - straight lines are curved. My end goal is to have a nice equirectangular panorama with straight lines. Thanks again


CValdes

bugbear

unread,
Jun 8, 2015, 11:15:39 AM6/8/15
to hugi...@googlegroups.com
Forex Valdes wrote:
> Thanks Terry
> Let me see if I got it right. I am using equirectangular.

> ... or you do two steps in one projecting and removing distorsion?

That's how it works. it's analagous to wanting to multiply by 2 and then by 3.

Hugin multiplies by 6. :-)

BugBear

Don Johnston

unread,
Jun 8, 2015, 12:52:00 PM6/8/15
to Hugin Pano
And other then multiplying by six, hugin even divides sometimes (very complex algorithms)! ;o)

Although, if you understand computers you know that all they can do is add 1s and 0s!

> --
> A list of frequently asked questions is available at: http://wiki.panotools.org/Hugin_FAQ
> ---
> You received this message because you are subscribed to the Google Groups "hugin and other free panoramic software" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to hugin-ptx+...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/hugin-ptx/5575B194.2070901%40papermule.co.uk.
> For more options, visit https://groups.google.com/d/optout.

Terry Duell

unread,
Jun 8, 2015, 5:54:04 PM6/8/15
to hugi...@googlegroups.com
Hello Forex,

On Tue, 09 Jun 2015 00:43:37 +1000, Forex Valdes <cvald...@gmail.com>
wrote:

> Thanks Terry
> Let me see if I got it right. I am using equirectangular.
> I was thinking that you need to remove distorsion before you project to
> equirectangular so the images to be projected have straight lines and not
> curved, and no fish eye effect. But you say you project to
> equirectangular and the projection will help to remove the fisheye
> effect? or you do two
> steps in one projecting and removing distorsion?

Yes, changing the projection can remove fisheye distortion, but are you
referring to lens distortion as well? If yes, then you need to have
calibration data for your lens, or stitch overlapping images from the lens
so that hugin can derive the lens parameters and make the correction.

> If I see my original pictures they show distorsion - straight lines are
> curved. My end goal is to have a nice equirectangular panorama with
> straight lines. Thanks again

If you want straight lines to be straight, then rectilinear projection is
required for that, but it is really only usable for angles of view less
than about 120 degrees. Greater than that and the image becomes distorted.
Load your image into hugin, ensuring you define the correct projection
type and FOV if hugin asks for that, and then view the image in the Fast
Panorama preview window. You can alter the projection in the projection
tab.

have a look here
<http://www.cambridgeincolour.com/tutorials/image-projections.htm> for
info on projections, and there are probably many other sites as well.
Have you looked at the hugin tutorials at
<http://hugin.sourceforge.net/tutorials/index.shtml> ?
They may help your understanding of how to use hugin.
Reply all
Reply to author
Forward
0 new messages