diff --git a/code/FBXConverter.cpp b/code/FBXConverter.cpp index 76b6c6b4e..ab600e53d 100644 --- a/code/FBXConverter.cpp +++ b/code/FBXConverter.cpp @@ -90,7 +90,8 @@ namespace Assimp { , anim_fps() , out(out) , doc(doc) - , mRemoveEmptyBones( removeEmptyBones ) { + , mRemoveEmptyBones( removeEmptyBones ) + , mCurrentUnit( FbxUnit::Undefined ) { // animations need to be converted first since this will // populate the node_anim_chain_bits map, which is needed // to determine which nodes need to be generated. @@ -3474,6 +3475,10 @@ void FBXConverter::SetShadingPropertiesRaw(aiMaterial* out_mat, const PropertyTa out->mMetaData->Set(14, "CustomFrameRate", doc.GlobalSettings().CustomFrameRate()); } + void FBXConverter::ConvertToUnitScale(FbxUnit unit) { + + } + void FBXConverter::TransferDataToScene() { ai_assert(!out->mMeshes); diff --git a/code/FBXConverter.h b/code/FBXConverter.h index a77cb4310..75f24713e 100644 --- a/code/FBXConverter.h +++ b/code/FBXConverter.h @@ -415,6 +415,21 @@ private: void ConvertGlobalSettings(); + enum class FbxUnit { + cm = 0, + m, + km, + inch, + foot, + mile, + yard, + NumUnits, + + Undefined + }; + + void ConvertToUnitScale(FbxUnit unit); + // ------------------------------------------------------------------------------------------------ // copy generated meshes, animations, lights, cameras and textures to the output scene void TransferDataToScene(); @@ -456,6 +471,8 @@ private: const FBX::Document& doc; bool mRemoveEmptyBones; + + FbxUnit mCurrentUnit; }; } diff --git a/code/FBXMeshGeometry.cpp b/code/FBXMeshGeometry.cpp index 2debfa651..468ba1c2e 100644 --- a/code/FBXMeshGeometry.cpp +++ b/code/FBXMeshGeometry.cpp @@ -568,8 +568,8 @@ void MeshGeometry::ReadVertexDataColors(std::vector& colors_out, cons } // ------------------------------------------------------------------------------------------------ -static const std::string TangentIndexToken = "TangentIndex"; -static const std::string TangentsIndexToken = "TangentsIndex"; +static const char *TangentIndexToken = "TangentIndex"; +static const char *TangentsIndexToken = "TangentsIndex"; void MeshGeometry::ReadVertexDataTangents(std::vector& tangents_out, const Scope& source, const std::string& MappingInformationType, diff --git a/code/FBXParser.cpp b/code/FBXParser.cpp index b255c4734..fe63866a0 100644 --- a/code/FBXParser.cpp +++ b/code/FBXParser.cpp @@ -117,7 +117,7 @@ namespace FBX { Element::Element(const Token& key_token, Parser& parser) : key_token(key_token) { - TokenPtr n = NULL; + TokenPtr n = nullptr; do { n = parser.AdvanceToNextToken(); if(!n) {