[VCS-1030] fallback for non-found .mtl file: try file name of original obj with just the file extension replaced by "mtl"

This commit is contained in:
Robert Liebo
2016-03-22 18:38:28 +01:00
committed by ViewAR Win32
parent 76e4e82ecb
commit abb3e6b854
3 changed files with 15 additions and 7 deletions

View File

@@ -177,7 +177,7 @@ void ObjFileImporter::InternReadFile( const std::string &file, aiScene* pScene,
m_progress->UpdateFileRead(1, 3);
// parse the file into a temporary representation
ObjFileParser parser(m_Buffer, modelName, pIOHandler, m_progress);
ObjFileParser parser(m_Buffer, modelName, pIOHandler, m_progress, file);
// And create the proper return structures out of it
CreateDataFromImport(parser.GetModel(), pScene);