1
0
Fork 0

Splash Screen fixes:

Specify type for options that are passed into the readRefImageFile (ref: devlist Andreas Mueller 14/03)
This commit is contained in:
Richard Harrison 2020-03-23 17:41:45 +01:00
parent 5dc2f20848
commit 9034ed5d46

View file

@ -295,11 +295,12 @@ void SplashScreen::setupLogoImage()
return;
}
#if OSG_VERSION_LESS_THAN(3,4,0)
_logoImage = osgDB::readImageFile(logoPath.utf8Str());
#else
auto staticOptions = simgear::SGReaderWriterOptions::copyOrCreate(osgDB::Registry::instance()->getOptions());
osg::ref_ptr<simgear::SGReaderWriterOptions> staticOptions = simgear::SGReaderWriterOptions::copyOrCreate(osgDB::Registry::instance()->getOptions());
staticOptions->setLoadOriginHint(simgear::SGReaderWriterOptions::LoadOriginHint::ORIGIN_SPLASH_SCREEN);
#if OSG_VERSION_LESS_THAN(3, 4, 0)
_logoImage = osgDB::readImageFile(logoPath.utf8Str(), staticOptions);
#else
_logoImage = osgDB::readRefImageFile(logoPath.utf8Str(), staticOptions);
#endif
if (!_logoImage) {