From 35e84b704d2ef7656c7f7ebfcedb67b167788eac Mon Sep 17 00:00:00 2001 From: "U-BAMS\\philippe.renon" Date: Thu, 18 Aug 2022 21:11:26 +0200 Subject: [PATCH] update OSG and OSGEarth --- ground/gcs/src/libs/osgearth/copydata.pro | 11 ++--------- .../gcs/src/libs/osgearth/osgQtQuick/OSGCamera.cpp | 2 +- .../gcs/src/libs/osgearth/osgQtQuick/OSGSkyNode.cpp | 12 ++++++------ .../osgearth/osgQtQuick/ga/OSGEarthManipulator.cpp | 2 +- .../gcs/src/libs/osgearth/osgearth_dependencies.pri | 4 ++-- 5 files changed, 12 insertions(+), 19 deletions(-) diff --git a/ground/gcs/src/libs/osgearth/copydata.pro b/ground/gcs/src/libs/osgearth/copydata.pro index 294471afe..cec63961e 100644 --- a/ground/gcs/src/libs/osgearth/copydata.pro +++ b/ground/gcs/src/libs/osgearth/copydata.pro @@ -160,11 +160,7 @@ win32:osg { win32:osgearth { # osgearth libraries OSGEARTH_LIBS = \ - libosgEarth$${DS}.dll \ - libosgEarthAnnotation$${DS}.dll \ - libosgEarthFeatures$${DS}.dll \ - libosgEarthSymbology$${DS}.dll \ - libosgEarthUtil$${DS}.dll + libosgEarth$${DS}.dll # loaded dynamically (probably by an osg plugin, need to find by which) OSGEARTH_LIBS += \ @@ -181,11 +177,8 @@ win32:osgearth { # osgearth plugins OSGEARTH_PLUGINS += \ mingw_osgdb_earth$${DS}.dll \ - mingw_osgdb_osgearth_arcgis$${DS}.dll \ - mingw_osgdb_osgearth_engine_mp$${DS}.dll \ + mingw_osgdb_osgearth_engine_rex$${DS}.dll \ mingw_osgdb_osgearth_sky_simple$${DS}.dll \ - mingw_osgdb_osgearth_tms$${DS}.dll \ - mingw_osgdb_osgearth_xyz$${DS}.dll \ mingw_osgdb_osgearth_cache_filesystem$${DS}.dll # more osgearth plugins diff --git a/ground/gcs/src/libs/osgearth/osgQtQuick/OSGCamera.cpp b/ground/gcs/src/libs/osgearth/osgQtQuick/OSGCamera.cpp index 0db64ce40..9c1d0d296 100644 --- a/ground/gcs/src/libs/osgearth/osgQtQuick/OSGCamera.cpp +++ b/ground/gcs/src/libs/osgearth/osgQtQuick/OSGCamera.cpp @@ -31,7 +31,7 @@ #include #ifdef USE_OSGEARTH -#include +#include #endif #include diff --git a/ground/gcs/src/libs/osgearth/osgQtQuick/OSGSkyNode.cpp b/ground/gcs/src/libs/osgearth/osgQtQuick/OSGSkyNode.cpp index 17e2f21cc..32d6cf0bb 100644 --- a/ground/gcs/src/libs/osgearth/osgQtQuick/OSGSkyNode.cpp +++ b/ground/gcs/src/libs/osgearth/osgQtQuick/OSGSkyNode.cpp @@ -34,7 +34,7 @@ #include #include #include -#include +#include // #include @@ -49,7 +49,7 @@ struct OSGSkyNode::Hidden : public QObject { private: OSGSkyNode * const self; - osg::ref_ptr skyNode; + osg::ref_ptr skyNode; public: OSGNode *sceneNode; @@ -102,7 +102,7 @@ public: self->setNode(NULL); return; } - if (!mapNode->getMap()->isGeocentric()) { + if (!mapNode->isGeocentric()) { qWarning() << "OSGSkyNode::updateScene - map node is not geocentric"; self->setNode(NULL); return; @@ -128,9 +128,9 @@ public: } } - osgEarth::Util::SkyNode *createSimpleSky(osgEarth::MapNode *mapNode) + osgEarth::SkyNode *createSimpleSky(osgEarth::MapNode *mapNode) { - return osgEarth::Util::SkyNode::create(mapNode); + return osgEarth::SkyNode::create(/*mapNode*/); } /* @@ -196,7 +196,7 @@ public: } double d = minimumAmbientLight; // skyNode->getSunLight()->setAmbient(osg::Vec4(d, d, d, 1.0f)); - skyNode->setMinimumAmbient(osg::Vec4(d, d, d, 1.0f)); + //skyNode->setMinimumAmbient(osg::Vec4(d, d, d, 1.0f)); } void attachSkyNode(osgViewer::View *view) diff --git a/ground/gcs/src/libs/osgearth/osgQtQuick/ga/OSGEarthManipulator.cpp b/ground/gcs/src/libs/osgearth/osgQtQuick/ga/OSGEarthManipulator.cpp index 4da67960d..7573e31f7 100644 --- a/ground/gcs/src/libs/osgearth/osgQtQuick/ga/OSGEarthManipulator.cpp +++ b/ground/gcs/src/libs/osgearth/osgQtQuick/ga/OSGEarthManipulator.cpp @@ -29,7 +29,7 @@ #include "../OSGNode.hpp" -#include +#include #include diff --git a/ground/gcs/src/libs/osgearth/osgearth_dependencies.pri b/ground/gcs/src/libs/osgearth/osgearth_dependencies.pri index 964568f37..3dfb0cedb 100644 --- a/ground/gcs/src/libs/osgearth/osgearth_dependencies.pri +++ b/ground/gcs/src/libs/osgearth/osgearth_dependencies.pri @@ -43,12 +43,12 @@ osgearth { linux|macx { INCLUDEPATH += $$OSGEARTH_SDK_DIR/include LIBS += -L$$OSGEARTH_SDK_DIR/$$LIB_DIR_NAME - LIBS += -losgEarth -losgEarthUtil -losgEarthFeatures -losgEarthSymbology -losgEarthAnnotation + LIBS += -losgEarth osgearthQt:LIBS += -losgEarthQt } win32 { - LIBS += -losgEarth$${DS} -losgEarthUtil$${DS} -losgEarthFeatures$${DS} -losgEarthSymbology$${DS} -losgEarthAnnotation$${DS} + LIBS += -losgEarth$${DS} osgearthQt:LIBS += -losgEarthQt$${DS} } }