Problem with deformation when stitching several scanned images

39 views
Skip to first unread message

abou...@eng.ucsd.edu

unread,
Aug 5, 2017, 2:00:58 AM8/5/17
to hugin and other free panoramic software
Hi, 

I have downloaded Hugin cause I try to find an equivalent of the Photoshop Automate --> Automerge option to stitch several scanned images together, but when I am doing it with Hugin, the final image is deformed (as it was flatten see the comparison with Photoshop below), I searched a little but I didn't find how to correct that (sorry I am also a beginner). If someone has an idea, suggestion or the answer that would help me a lot thank you! 

Here are the final images created with Hugin (first one) and Photoshop (second one) to see the point: 



T. Modes

unread,
Aug 5, 2017, 6:08:43 AM8/5/17
to hugin and other free panoramic software


Am Samstag, 5. August 2017 08:00:58 UTC+2 schrieb abou...@eng.ucsd.edu:
If someone has an idea, suggestion or the answer that would help me a lot thank you! 

Set the output projection to rectilinear (default is equirectancular).

Abrimaal

unread,
Aug 5, 2017, 6:29:16 AM8/5/17
to hugin and other free panoramic software
The problem is that Hugin does not offer undistorted projection, suitable for scanned documents.
Thy this:
00. Before all, note down the dimensions in pixels of each partial image.
01. Load all images to Hugin
02. Set the projection to rectilinear
03. Go to Panorama Editor, Control Points tab
04. Open the same images in both view panels
05. Add two horizontal and two vertical lines. Click near the top left in the first panel and near the top right in the 2nd panel.
06. Now you have the first horizontal line. Correct the numeric values to x=0, y=0 and x=0, y=image width.
07. Do the same for the 2nd horizontal line at the bottom and two vertical lines. Then repeat the steps for all images.
08. Go to Photos tab, create control points using the Hugin CPFind.
09. Go back to the main window, save the project. This is important is something goes wrong, you can always go back (you can use Undo too, but saving is safer)
10. Back to the Editor. There are several metods of optimizing the geometrics. Try the first one (positions, incremental). If it looks not perfectly, undo and try another method.
11. You can save every method as a panorama, then compare the images. I recommend this to compare the images in full screen viewer.
11. Optimizing photometrics is optional, usable only when the images were scanned with auto exposition, auto fix, auto contrast etc.

This way I stitched some maps, but it took a lot of time and work. Easier to go to a printing service, they have A0 scanners there.

T. Modes

unread,
Aug 5, 2017, 6:43:10 AM8/5/17
to hugin and other free panoramic software


Am Samstag, 5. August 2017 12:29:16 UTC+2 schrieb Abrimaal:
The problem is that Hugin does not offer undistorted projection, suitable for scanned documents.
???? Rectilinear should be sufficient for scanned documents.
 
Thy this:
Don't do this. See comment below:
 
05. Add two horizontal and two vertical lines. Click near the top left in the first panel and near the top right in the 2nd panel.
06. Now you have the first horizontal line. Correct the numeric values to x=0, y=0 and x=0, y=image width.
07. Do the same for the 2nd horizontal line at the bottom and two vertical lines. Then repeat the steps for all images.
This would only help if all images would be exactly straight and no rotation between the images. In praxis this is never the case, you have always a little rotation between the different images. And this approach confuses the optimizer.

10. Back to the Editor. There are several metods of optimizing the geometrics. Try the first one (positions, incremental). If it looks not perfectly, undo and try another method.
11. You can save every method as a panorama, then compare the images. I recommend this to compare the images in full screen viewer.
Sorry, but you don't have understand the concept of optimization and what each optimization setting does.
Optimization is an iterative process. Sometimes it can takes several step to the end result. But undo after the first step makes it even worse.


abou...@eng.ucsd.edu

unread,
Aug 5, 2017, 2:01:42 PM8/5/17
to hugin and other free panoramic software
Indeed I had not changed the default output projection setting, it now works very well with the rectilinear one thank you !! 
Reply all
Reply to author
Forward
0 new messages