leveling horizon commandline

103 views
Skip to first unread message

Hans Hermans

unread,
Apr 23, 2015, 5:01:06 PM4/23/15
to hugi...@googlegroups.com
I have a script that automates the creation of 360 degr. panoramic images.
There are differences in the output with the leveling of the horizon with autooptimiser from hugin 2013 and from hugin 2014 when i run autooptimiser -l from the commandline.
Hugin 2013 gets the right result, hugin 2014 doesn't. With hugin 2014 i can't get it working properly.
See attached images.



hugin2013.jpg
hugin2014.jpg

Carlos Eduardo G. Carvalho (Cartola)

unread,
Apr 24, 2015, 8:31:23 AM4/24/15
to hugi...@googlegroups.com
Hi, when I've made a script I have levelled my pano finding vertical lines with the linefind command.

You can run it on a pto file using the same pto as output, like:

linefind -o file.pto file.pto

You can also run it on one image at a time with "-i" option inside a loop:

linefind -o file.pto -i $image_number file.pto

where $image_number goes from 0 to total images - 1.

Bests,

--
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/1219e852-0f96-4ec5-9c52-1ecd2f1c82b5%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

T. Modes

unread,
Apr 26, 2015, 4:29:37 AM4/26/15
to hugi...@googlegroups.com

Between Hugin 2013.0 and 2014.0 the leveling code was not changed.
So check the commands and the pto file *before* the leveling step for differences.

Hans Hermans

unread,
May 6, 2015, 3:56:08 PM5/6/15
to hugi...@googlegroups.com
I have added my script and the .pto file i use as a template. Can you please take a look if you see where anything goes wrong?

Op donderdag 23 april 2015 23:01:06 UTC+2 schreef Hans Hermans:
panorama1.pto
panobot2015_1.txt

Hans Hermans

unread,
May 6, 2015, 4:10:31 PM5/6/15
to hugi...@googlegroups.com
The goal of my project is to automate the whole process from taking the images (with a self build panobot) to a ready to publish html5 panoramic image.
See for more details: https://www.youtube.com/watch?v=QV_uigh_yJI


Op donderdag 23 april 2015 23:01:06 UTC+2 schreef Hans Hermans:
I have a script that automates the creation of 360 degr. panoramic images.

T. Modes

unread,
May 9, 2015, 4:31:13 AM5/9/15
to hugi...@googlegroups.com


Am Mittwoch, 6. Mai 2015 21:56:08 UTC+2 schrieb Hans Hermans:
I have added my script and the .pto file i use as a template. Can you please take a look if you see where anything goes wrong?

 This helps not so much. We need the pto *direct before* leveling, ideally one from Hugin 2013.0 and another one Hugin 2014.0

Thomas

Hans Hermans

unread,
May 11, 2015, 11:15:13 AM5/11/15
to hugi...@googlegroups.com
I have added the .pto file from the 2013 version and the 2015 version (that gives me the same result as the 2014 version) before and after leveling.


Op donderdag 23 april 2015 23:01:06 UTC+2 schreef Hans Hermans:
I have a script that automates the creation of 360 degr. panoramic images.
hugin2013-after.pto
hugin2013_before.pto
hugin2015_after.pto
hugin2015_before.pto

Hans Hermans

unread,
May 11, 2015, 11:24:32 AM5/11/15
to hugi...@googlegroups.com
i have added the wrong hugin2013_.. files


Op donderdag 23 april 2015 23:01:06 UTC+2 schreef Hans Hermans:
I have a script that automates the creation of 360 degr. panoramic images.
hugin2013_after.pto
hugin2013_before.pto
hugin2015_after.pto
hugin2015_before.pto

T. Modes

unread,
May 11, 2015, 2:19:54 PM5/11/15
to hugi...@googlegroups.com


Am Montag, 11. Mai 2015 17:24:32 UTC+2 schrieb Hans Hermans:
i have added the wrong hugin2013_.. files


Thanks. Found the bug. It happens only in this special combination (leveling of landscape images which have the orientation flag set to portrait mode).
This is fixed in repository and should be in next version (2015.0 beta 3 or rc1).

Thomas

PS: Your script has a lot room for improvements.

1.) The Hugin parts runs too much commands. The following 4 lines should be sufficient
cpfind --prealigned -o panorama1.pto panorama1.pto
cpclean -o panorama1.pto panorama1.pto
pto_var --opt y,p,r,v,b,c,d,e -o panorama1.pto panorama1.pto
autooptimiser -n -m -l -o  panorama1.pto panorama1.pto
This should reduce the overhead.

2.) I don't know what you want to achieve with the first convert line:
convert panorama.tif -gravity north -extent 7762x3881 panorama.tif
nona and enblend should already generate an image with this dimension because your pto file contains ..w7762 h3881..
Message has been deleted

Hans Hermans

unread,
May 12, 2015, 3:02:55 AM5/12/15
to hugi...@googlegroups.com
Thanks for your help!
I will update the script. Most is new for me and work in progress.


Op donderdag 23 april 2015 23:01:06 UTC+2 schreef Hans Hermans:
I have a script that automates the creation of 360 degr. panoramic images.

Hans Hermans

unread,
May 14, 2015, 5:31:34 PM5/14/15
to hugi...@googlegroups.com
The bug is solved in the nightly builds indeed. Thanks for that!
I have an other question. I discovered that the inbuilt blender gives better results than blender gives. Is it possible to use it in my script instead of blender and what is the command to use?


Op donderdag 23 april 2015 23:01:06 UTC+2 schreef Hans Hermans:
I have a script that automates the creation of 360 degr. panoramic images.

Terry Duell

unread,
May 14, 2015, 7:33:12 PM5/14/15
to hugi...@googlegroups.com
Hello Hans,

On Fri, 15 May 2015 07:31:34 +1000, Hans Hermans <picam...@gmail.com>
wrote:

> The bug is solved in the nightly builds indeed. Thanks for that!
> I have an other question. I discovered that the inbuilt blender gives
> better results than blender gives. Is it possible to use it in my script
> instead of blender and what is the command to use?
>

See pano_modify

Cheers,
--
Regards,
Terry Duell
Reply all
Reply to author
Forward
0 new messages