YujinJung/FBX-Loader

Mistakes with Reading exported skeleton data file when there is a blank in the Bone Name

Opened this issue · 0 comments

  1. Anther problem is when I using a FBX model file and if there is a blank in a bone name, like "Bip001 R Toe0", "Bip001 R Clavicle" etc., it will make mistakes when invoking the "ExportSkeleton()" function, and the bones hierachy and names in the .skeleton files exported will be wrong. When invoking the "LoadSkeleton()" function next time it will be in error. So I replace the blank with a "|" in the code below, which is in the
    `void FbxLoader::ExportSkeleton(

          SkinnedData& outSkinnedData, 
    
          const std::string& clipName, 
    
          std::string fileName)`
    

function,

`
   skeletonFileOut << "BoneName" << "\n";

	for (auto& e : outSkinnedData.GetBoneName())

	{

		//skeletonFileOut << e << " ";

		skeletonFileOut << e << "|";

	}
  `

then the skeleton file were exported and loaded correctly.
Wish it can help!Thanks bro!