Thanks Robert, for include/osg/Config. Starting with OSG 2.6, the VTP can now check OSG_USE_FLOAT_MATRIX to detect whether OSG was built with float matrices or not. That makes it easy to handle both cases, so the user doesn't need it built one way or the other.
It is not so surprising that the VTP prefers float matrices: 1. It is pointless to use the extra RAM (and memory bandwidth, and CPU time) for double matrices, when they aren't needed. 2. The rest of VTP's stack uses single matrices, so having OSG use doubles does not even gain theoretical precision improvement. It would have to be all doubles, top to bottom. 3. OpenGL itself is single-precision, so at best doubles would affect temporary, intermediate computations. 4. In many years, i have never encountered any rare situation that would be improved with double matrices. I'm certain they exist (among the many unusual uses of OSG) but since they are less common, it would make far more sense for single matrices to be the default. The VTP uses double-precision for GIS data, and single-precision for the 3d scenegraph. A design which requires the scenegraph to be double-precision is arguably.. an odd choice. -Ben > -----Original Message----- > From: Robert Osfield > Sent: Saturday, September 13, 2008 2:29 AM > > Hi Pascal, > > I wonder if you could add something to the VTP build system to detect > problems with Matrixd being used for Matrix. The other thing one > might be able to do is adapt VTP so that it can handle Matrxf and > Matrixd versions of Matrix. With OSG 2.6 onward there now is an > include/osg/Config which includes details of the which version of > Matrix is used, perhaps this might be of some help. > > As a general note, I've always been surprised by VTP using float > Matrices, as GIS related app I would have expect double Matrices as it > solves many of the precision problems associated with real world data. > > Robert. > > On Sat, Sep 13, 2008 at 9:40 AM, Pascal Rheinert > <[EMAIL PROTECTED]> wrote: > > Hi, > > I got exactly the same error when trying to start VTP > > And I solved it now: > > The reason is (as expected) a discrepency between what > > OSG does by default and what VTP expects concerning > > the Matrix _______________________________________________ osg-users mailing list osg-users@lists.openscenegraph.org http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org