toon-members
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Toon-members] TooN 2.0 Windows / MSVC++ Portability


From: Greg Andrews
Subject: [Toon-members] TooN 2.0 Windows / MSVC++ Portability
Date: Wed, 6 May 2009 10:19:56 -0400

Gentlemen -

Thanks for providing the TooN and related libraries... they are very useful.  I've found some issues when trying to use TooN 2.0 under Visual Studio in a Windows environment:

1.) There are a few places where things are first defined as a struct, and later a class.  This seems to wreak havoc w/ MSVC.  Making the following changes seems to help:
       vector.hh, line 128   (change class -> struct )
       mbase.hh, line 39    (change class -> struct )
       matrix.hh, line 34     (change class -> struct )
       TooN.h, line 77        (change class -> struct )
       diagmatrix.h, line 56 (change class -> struct )

2.) In objects.h, I was getting errors about Identity being doubly defined.  I moved the definition:
template<class Pr> struct Operator<Internal::Identity<Pr> >
so that it's above
template<class Precision> struct Operator<Internal::SizedIdentity<Precision> >

3.) M_PI and M_SQRT1_2 don't seem to be defined in my build environment.  At the top of so3.h, I added:
#ifdef WIN32
#define M_PI 3.14159265358979323846
#define M_SQRT1_2 0.70710678118654752440
#endif

I was hoping you might be able to make these (or similar) changes so that I can use the TooN CVS repository without keeping my own Windows-only version.

Thanks!,
-Greg


reply via email to

[Prev in Thread] Current Thread [Next in Thread]