Fix FBX units not being converted from CM to application scale

pull/2620/head
Gordon MacPherson 2019-08-26 20:37:49 +01:00
parent f119fedd55
commit d56198774e
1 changed files with 2 additions and 2 deletions

View File

@ -193,8 +193,8 @@ void FBXImporter::InternReadFile( const std::string& pFile, aiScene* pScene, IOS
// convert the FBX DOM to aiScene
ConvertToAssimpScene(pScene, doc, settings.removeEmptyBones, unit);
// Set file scale relative to meters
SetFileScale( doc.GlobalSettings().UnitScaleFactor() );
// units is relative to CM :) we need it in meters for assimp
SetFileScale( doc.GlobalSettings().UnitScaleFactor() * 0.01f);
std::for_each(tokens.begin(),tokens.end(),Util::delete_fun<Token>());
}