Building Autopano-SIFT-C

337 views
Skip to first unread message

Henk Tijdink

unread,
Oct 8, 2010, 5:00:16 AM10/8/10
to hugin and other free panoramic software
Building Autopano SIFT-C 2.5.1

Succeeded in building Autopano SIFT-C 2.5.1 in a rather simple way
after (a long time) studying the Hugin SDK (MSVC 2008) in the WIKI and
a lot of trial and error.
I only have doubt about the quality of the build. Here are my steps
till now.
I'm not experienced in building, but gave it a try. Most steps done
according this WIKI page.
See <http://wiki.panotools.org/Hugin_SDK_(MSVC_2008)>

Needed only as described in the WIKI under Autopano-SIFT-C the 3
dependencies that are in the HUGIN SDK, Visual Studio and CMake.

a) MS Visual Studio Express 2008.
Download page:<http://www.microsoft.com/express/Downloads/>
You have to download VisualC++ 2008 Express edition.

b) Cmake 2.8.2 <http://www.cmake.org/files/v2.8/cmake-2.8.2-win32-
x86.zip>
You can download an installer too
<http://www.cmake.org/files/v2.8/cmake-2.8.2-win32-x86.exe>
c) Hugin SDK
<http://hugin.panotools.org/sdk/MSVC/Hugin-SDK-20090509-win32.exe>

d) Autopano-SIFT-C-2.5.1.tar.gz
<http://sourceforge.net/projects/hugin/files/autopano-sift-C/autopano-
sift-C-2.5.1/autopano-sift-C-2.5.1.tar.gz/download>

1 First install VisualC++ 2008 express edition.

2 Extract or installl CMake 2.8.2

3 From the Hugin SDK extract only
a)libpano
b)libxml2-2.7.3
c)wxWidgets-2.8.10

To folder D:\SDKHome.
(I use this naming for easy comparision with the WIKI page.)

The other folders are not necessary for building Autopano-SIFT-C.
In the SDK are Autopano-SIFT-C binaries, but that is version is 2.5.0.

4 Extract Autopano-SIFT-C-2.5.1.tar.gz to D:\SDKHome.

5 Rename folder to Autopano-SIFT-C-Trunk

6 Start CMake GUI(In folder...CMake\bin)

7 browse to folder D:\SDKHome\Autopano-SIFT-C-Trunk as source.

8 browse to folder D:\SDKHome\and add Autopano-SIFT-C.
A dialogue asks to create that folder. click yes
A dialogue appears for selecting the generator.
select Use default native compilers and select Visual Studio 9 2008.

CMake prepares the configuration and you see every line in red.
Everything is found except the SVN number.

Imho no objection, because it was a straight download of the latest
stable version and not via Tortoise.
This year there has been no updates for Autopano-SIFT-C.

9 Click configure. The red backgound is gone.

10 Generate. Everything is generated. Close CMake.

11 Go to folder D:\SDKHome\Autopano-SIFT-C and open autopano-sift-
C.sln.
Visual studio starts.

12 Select Release in Solution Configuration pull-down menu, and then
choose Build > Build Solution.
It builds ALL, but one file fails.

13 Select project INSTALL in Solution Explorer, and then choose Build
> Project Only > Build Only INSTALL
Then install is build.

14 Close Visual C++ 2008 Express Edition.

Now Autopano-SIFT-C resides in folder D:\SDKHome\Autopano-SIFT-C
\install.
In folder bin are the CPG's, both the 1 step(Autopano-SIFT-C) and 2
step(autopano and getkeys) and in the folder share the manuals.
You only need to keep those 2 folders in folder Autopano-SIFT-C.

However when checking the logs in the Autopano-SIFT-C folder there is
one folder with warnings, the Libsift\release folder.
8 lines with warning:conversion from 'double' to 'float', possible
loss of data
3 lines with warning:signed/unsigned mismatch.

Further the package folder fails to build. the log file says it
misses:
Performing Post-Build Event...
CPack Error: Cannot find NSIS registry value. This is usually caused
by NSIS not being installed. Please install NSIS from http://nsis.sourceforge.net
CPack Error: Cannot initialize the generator NSIS
Project : error PRJ0019: A tool returned an error code from
"Performing Post-Build Event..."

Tested the 1 step and 2 step generators and both worked. Only did it
with 2 images.

I'm only wondering if this build is correct and not corrupted by the
warnings and the fail of the package folder or that I'm doing
something wrong during the build. this because the size of autopano-
sift-C.exe is 1243kB and the downloaded version of autopano-SIFT-C.exe
is 1019kB

Can experienced builders compilers advise me if this build is
correct?.

Kind regards,
Henk Tijdink

davidefa

unread,
Oct 8, 2010, 9:51:32 AM10/8/10
to hugin and other free panoramic software
Though I'm not a windows expert, I have built autopano-sift-c-2.5.1
with MSVC2008 in a similar way ( following the wiki tutorial ).
Buiding autopano-sift-c-2.5.2 ( from mercurial repository ) returned
an error in DisplayImage.c line 338 ( costant out of range: fixed by
changing constant to 3.402823466e+38F )

Regards

Aron H

unread,
Oct 8, 2010, 10:19:07 AM10/8/10
to hugin and other free panoramic software


On Oct 8, 5:00 am, Henk Tijdink <h.tijd...@gmail.com> wrote:
> Building Autopano SIFT-C 2.5.1
> ....................
> I'm only wondering if this build is correct and not corrupted by the
> warnings and the fail of the package folder or that I'm doing
> something wrong during the build. this because the size of autopano-
> sift-C.exe is 1243kB and the downloaded version of autopano-SIFT-C.exe
> is 1019kB
>
> Can experienced builders compilers advise me if this build is
> correct?.

Hi Henk,
Based on my experience, I think your build is successful. The
conversion warnings should not be a problem, and the PACKAGE target is
only needed to build an installer for autopano-sift-c, which I expect
we will not need. ThePanz and Matthew have been doing Windows
installers, and their newest installers will go get an archive from a
download site and put the .exe files in the Hugin bin/ directory, if I
understand how they work.

Have you tested your build from inside Hugin? Does it work so far?

>
> Kind regards,
> Henk Tijdink

Henk Tijdink

unread,
Oct 8, 2010, 12:39:11 PM10/8/10
to hugin and other free panoramic software
Yes I've done a short test with only 2 pictures.
With the following parameters for Autopano-SIFT-C

a) --maxmatches %p --projection %f,%v %o %i
b) --maxmatches %p %o %s

These are the parameters Bruno Postle advises in the following thread.
http://groups.google.com/group/hugin-ptx/msg/bb3b5d9b13d6aa08
I have tested it and both sets of parameters works OK.

The generatekeys.exe and autopano.exe in 2 step mode for multirow are
working with the defaults parameters in Hugin too.
I was not worrying about the missing installer because you don't need
it.
I'm worrying more about the warnings in LIBSIFT.
Futher I'm worrying because the downloaded Autopano-SIFT-C is 1019kB
and my build is 1243kB
Here is the link to the downloaded version.
<http://www.google.com/url?sa=D&q=http://www.sendspace.com/file/
0mgb8o&usg=AFQjCNEGZfjT79MQ4JGZOseiJ8cmYQrBmg>
I should expect the same size for the files.

Kind regards,
Henk

Henk Tijdink

unread,
Oct 8, 2010, 12:58:47 PM10/8/10
to hugin and other free panoramic software
Sorry the download adres of the downloadable Autopano-SIFT-C2.5.1 is
wrong in above post.
It is:<http://www.sendspace.com/file/0mgb8o>
Anyway if Autopano-SIFT-C 2.5.1 is not corrupted, this thread is a
good instruction for building it by a novice in compiling and
building.

Kind regards,
Henk

On 8 okt, 18:39, Henk Tijdink <h.tijd...@gmail.com> wrote:
> Yes I've done a short test with only 2 pictures.
> With the following parameters for Autopano-SIFT-C
>
> a)  --maxmatches %p --projection %f,%v %o %i
> b)  --maxmatches %p %o %s
>
> These are the parameters Bruno Postle advises in the following thread.http://groups.google.com/group/hugin-ptx/msg/bb3b5d9b13d6aa08

davidefa

unread,
Oct 8, 2010, 2:19:36 PM10/8/10
to hugin and other free panoramic software
May be the autopano-sift-c you linked was built with another compiler
( mingw?? ) or with another optimization.

In autopano.exe ( generally use v2.5.2 ) I use the following
parameters:

--maxmatches %p --ransac off %o %k

With 'ransac on' ( the default in autopano.exe ) sometimes generates 0
or a few control points

Henk Tijdink

unread,
Oct 9, 2010, 5:59:12 AM10/9/10
to hugin and other free panoramic software
Don't know if the 2 step generator of 2.5.2 is corrupted or broken too
as is Autopano-SIFT-C 2.5.2.
Perhaps that is possibly the reason you need to turn ransac off.
The experts only can make this issue clear.

Kind regards,
Henk

Tom Sharpless

unread,
Oct 11, 2010, 5:49:39 PM10/11/10
to hugin and other free panoramic software
Hi Henk

On Oct 8, 5:00 am, Henk Tijdink <h.tijd...@gmail.com> wrote:
> Building Autopano SIFT-C 2.5.1
>

> However when checking the logs in the Autopano-SIFT-C folder there is
> one folder with warnings, the Libsift\release folder.
> 8 lines with warning:conversion from 'double' to 'float', possible
> loss of data
> 3 lines with warning:signed/unsigned mismatch.

These are cosmetic so far as I can remember. MSVC is picky about
assigning literal values (which are officially of type double) to
variables of type float. I changed the data type for 'interest point'
coordinates and feature vectors from double to float, which almost
doubles the number of candidate points that can be handled on a given
machine. Signed/unsigned mismatch is usually due to comparing an int
variable with some type like size_t, defined as unsigned, which very
rarely leads to a true error. Trying to make MSVC 100% happy about
this is an exercise in futility.

>
> Further the package folder fails to build. the log file says it
> misses:
> Performing Post-Build Event...
> CPack Error: Cannot find NSIS registry value. This is usually caused
> by NSIS not being installed. Please install NSIS fromhttp://nsis.sourceforge.net
> CPack Error: Cannot initialize the generator NSIS
> Project : error PRJ0019: A tool returned an error code from
> "Performing Post-Build Event..."
>
There is no need to try to build a package. Or to try to make one
buildable.

> Tested the 1 step and 2 step generators and both worked. Only did it
> with 2 images.
>
> I'm only wondering if this build is correct and not corrupted by the
> warnings and the fail of the package folder or that I'm doing
> something wrong during the build. this because the size of autopano-
> sift-C.exe is 1243kB and the downloaded version of autopano-SIFT-C.exe
> is 1019kB
>
> Can experienced builders compilers advise me if this build is
> correct?.

If it doesn't crash I would say it probably is. There really has been
no formal testing or verification of these programs.

I would point out that the '1-step' program, which was largely my
doing, is very different internally from the original '2-step' one,
and that several of the command line options of the original simply
don't work in it, though still offered. And that it really needs more
development -- I'm fairly sure it could be made to find better sets of
control points, faster.

Regards, Tom

Bruno Postle

unread,
Oct 23, 2010, 11:50:38 AM10/23/10
to hugin and other free panoramic software

I'm not clear how or why this works as both numbers are within
range, was it just shortening the string that fixed it?

--
Bruno

davidefa

unread,
Oct 23, 2010, 12:57:40 PM10/23/10
to hugin and other free panoramic software
I rebuilt autopano-sift-c-2.5.2 ( with MSVC2008 )

a) with line 338:
float minval = 3.40282347e+38F; // Assumes 32 bit float, why
not?
I get the error:
..\autopano-sift-C-252\DisplayImage.c(338) : error C2177: constant too
big

according to MSVC2008's help maximum value for a 32 bit float is
3.402823466 E + 38 ( I don't know if this changed from previous
versions )

b) with line 338:
float minval = 3.402823466e+38F; // Assumes 32 bit float, why
not?
it compiles ok.


Bruno Postle

unread,
Oct 23, 2010, 5:46:29 PM10/23/10
to hugin and other free panoramic software
On Sat 23-Oct-2010 at 09:57 -0700, davidefa wrote:
> ..\autopano-sift-C-252\DisplayImage.c(338) : error C2177: constant too big
>
> according to MSVC2008's help maximum value for a 32 bit float is
> 3.402823466 E + 38 ( I don't know if this changed from previous
> versions )

Ok, the change seems to not break anything here, so I committed it.

--
Bruno

Yuval Levy

unread,
Oct 23, 2010, 6:02:40 PM10/23/10
to hugi...@googlegroups.com

Just to make sure Davide knows: I have added him to the project and he can
commits these changes directly. Thomas already committed the two celeste-
related bugfixes that Davide identified in the bug tracker.

benvenuto a bordo, Davide!

Yuv

signature.asc
Reply all
Reply to author
Forward
0 new messages