osgearth icon indicating copy to clipboard operation
osgearth copied to clipboard

'convertLocalToModel': is not a member of 'osgEarth::Util::GeoLocator'

Open marcoma9023 opened this issue 1 year ago • 3 comments

Hi,

Since I would like to migrate my project from osgearth 2 to 3, in building I have the following problem:

in the class TileModel of OsgEarth (line 230) the row with problem consist of

if (getLocator()->convertLocalToModel(osg::Vec3d(0.5,0.5,0.0), v))

this is because the getLocator methor return the object osgearth::Util::GeoLocator that don't have the method convertLocalToModel...

But comparing the class Locators of osgearth2.1 and 3.2, I noticed that in the old version, the class extends osgTerrain::Locator instead the new version don't extend that class and don't has this method.....

How can I solve?

marcoma9023 avatar Jul 28 '22 06:07 marcoma9023

Will the method GeoLocator::unitToWorld work for you? If not, and without knowing what you are using the method for, all I can suggest is that you reference the code for osgTerrain::Locator and incorporate that into your application. (If you are upgrading, version 3.3 is the latest release.)

gwaldron avatar Jul 28 '22 14:07 gwaldron

The basic problem is that I haven't used that method directly in my code, but indirectly there will be some call that OSGEarth does that I can't control ....

marcoma9023 avatar Jul 29 '22 06:07 marcoma9023

Wait, are you trying to compile the engine_mp plugin? That is no longer supported, and it should be disabled by default in the CMake configuration.

gwaldron avatar Jul 29 '22 12:07 gwaldron

Closing for inactivity.

gwaldron avatar Aug 29 '22 12:08 gwaldron