Import blender result of mixamo character in babylon scene

Hi, I know how I can convert Mixamo characters to babylonjs with blender, but when I import result in babylon, I get multi meshes, “unlike the dude in some example that is just one mesh”, how I can get all the character as single mesh? and if it is not possible, how I can clone the character mesh? I write some code that can clone the meshes but animation not working for them, what is my problem. thank you guys.
let meshes = [];
for(let k=0; k<oldChar.mesh.length; k++)
meshes.push(oldChar.mesh[k].clone(“m_”+k));
let skeletons = oldChar.skeleton.clone(“s_1”);
SCENE.beginAnimation(skeletons, 0, 120, 1.0, true);

by this code, meshes cloned but animation not working.

Hello, pinging @Vinc3r and @gryff to see if they can help on the Blender side

On Babylonjs side, there is no simple way to merge animated meshes into a single one without breaking everything.

Can you repro your issue regarding the clone in the Playground so we can point you to the right direction?

Hello,

If you have multiple meshes in blender that is what you are going to import in Babylon as well. In my personal opinion, you should definitely fix the model in blender and not join the meshes in Babylon. You can join the model by selecting the separate meshes and hitting ctrl + j and then export.

Cheers

1 Like

Yep, as Null said, fix your mesh inside your 3D modeler first (especially when dealing with animation/skining/etc).

As for object imported as multimesh, in case you’re using gltf format you have to know that each submaterial will be exported as one mesh.

I do not know if the gltf exporter for Blender does shapekeys, but if each material is exported as a mesh, then you definitely do not want to use it if you have shapekeys & multiple materials. That would be tedious to animate deforms across multiple meshes yourself.

Also, ctrl + j combines shapekeys of the same name. I do it all the time with meshes from makehuman.

Also, save the last select for the mesh you want all the others to be merged into.