FBXSDK – Load the animation from second FBX file
Hi! I have a two files FBX. First file is a model and contain mesh (vertices, uv, normals) but second file is only skeletal animation. I tried load second file – animation. I have a problem with this and my program show “mesh is empty” while load the animation. I write this program in C++ and OpenGL GLFW
FbxImporter* importer = FbxImporter::Create(manager, “”);
if (!importer->Initialize(model_pathfile.c_str(), -1, manager->GetIOSettings())) {
std::cout << “error with load model” << pathfile << “\n”;
return;
}
scene = FbxScene::Create(manager, “myScene”);
importer->Import(scene);
importer->Destroy();
FbxImporter* importer = FbxImporter::Create(manager, “”);
if (!importer->Initialize(anim_pathfile.c_str(), -1, manager->GetIOSettings())) {
std::wcout << “error with load animation ” << path << L”\n”;
return;
}
importer->Import(scene);
importer->Destroy();
Read more here: Source link
