Correct scenery load path extension.

This commit is contained in:
Mathias Froehlich 2011-12-11 22:19:11 +01:00
parent 945a9e0ac2
commit 057cbe7cc3

View File

@ -200,8 +200,12 @@ TileEntry::loadTileByFileName(const string& fileName,
osgDB::FilePathList path_list=options->getDatabasePathList();
// Make sure we find the original filename here...
std::string filePath = osgDB::getFilePath(fileName);
if (!filePath.empty())
path_list.push_front(filePath);
if (!filePath.empty()) {
SGPath p(filePath);
p.append("..");
p.append("..");
path_list.push_front(p.str());
}
// scan and parse all files and store information
for (unsigned int i = 0; i < path_list.size(); i++) {