My application does not start after updating osgEarth

classic Classic list List threaded Threaded
3 messages Options
_Alex_ _Alex_
Reply | Threaded
Open this post in threaded view
|

My application does not start after updating osgEarth

Hi all,
I've an application which works correctly with osgEarth (master 14.04.2016). After upgrading to osgEarth latest version, my application does not start. The debugger does not go into the main function of my application. I found a commit after which my application does not work.
This is the 06d4795e3a15197e32b2e26ca99a4ce3522bbbd3 committe (https://github.com/gwaldron/osgearth/commit/06d4795e3a15197e32b2e26ca99a4ce3522bbbd3) (Registry: add an async operations queue and thread pool).  If in Registry.cpp I comment the line  t-> start (), then my application starts successfully.    
i.e.

    // create the thread pool and tie it to the queue.
    for (unsigned i = 0; i < _threadPoolSize; ++i)
    {
        osg::OperationThread* t = new osg::OperationThread();
        t->setOperationQueue(_opQueue.get());
       // t->start(); // this is my comment
        _opThreadPool.push_back(t);
    }

In the latest version of osgEarth, these functions are in ElevationPool.cpp.
The problem is reproduced only on Windows. My application starts successfully on Linux. I use VS2010 and OSG 3.4.0.

Any ideas what is causing this? thanks a lot!
gwaldron gwaldron
Reply | Threaded
Open this post in threaded view
|

Re: My application does not start after updating osgEarth

Alex,
No idea, I'm afraid. Have you tried building against OSG 3.6.3 (latest stable release)?
Glenn Waldron / Pelican Mapping
_Alex_ _Alex_
Reply | Threaded
Open this post in threaded view
|

Re: My application does not start after updating osgEarth

I solved the problem. Cannot use static SpatialReference.

 i.e.  
const static SpatialReference* WGS84 = SpatialReference::get("wgs84");