csganja Posted January 14, 2017 Share Posted January 14, 2017 I have a *.blender model (actually just skeleton) used for animations. So, the ideea is to load 5 models (helm, armor, pants, gloves and boots) merge them and then apply the existing skeleton to the merged meshes. I'm stuck at applying the skeleton to the model (or the model to the skele???), that's all... but i have no idea how to do this... Quote Link to comment Share on other sites More sharing options...
aWeirdo Posted January 14, 2017 Share Posted January 14, 2017 meshVar.skeleton = skeletonVar; Quote Link to comment Share on other sites More sharing options...
csganja Posted January 20, 2017 Author Share Posted January 20, 2017 So, i just can't figure this out. I have 3 babylon files, one with meshes, one with skeleton and one combined [meshes+skeleton]. In Blender if i import the skeleton over the existing mesh [smd files] the animation is fine, but in babylon if i asign the skeleton to the mesh the animation is distorted. But if i use the combined file the animation is fine, as you can see in the screen [left is combined in blender, right is skeleton assisgned to meshes in babylon]... Any ideas? I would do a pg if you can explain me how to upload files, haven't seen anything like this... Quote Link to comment Share on other sites More sharing options...
adam Posted January 20, 2017 Share Posted January 20, 2017 Does this help? http://doc.babylonjs.com/tutorials/How_to_use_Bones_and_Skeletons#cloning-bones Quote Link to comment Share on other sites More sharing options...
Dad72 Posted January 20, 2017 Share Posted January 20, 2017 Another idea is also to create characters with a skeleton without animation and an animate skeleton apart and load that animations on the character with skeleton. It's just an idea. You can also load animations on the fly. This is what I do to load animations on the fly on a character http://www.babylonjs-playground.com/#GA8XI#12 gryff 1 Quote Link to comment Share on other sites More sharing options...
JCPalmer Posted January 20, 2017 Share Posted January 20, 2017 When you export a mesh without a skeleton in Blender, you do not get any matrix weights & index per vertex in the .babylon file for the mesh. You cannot add a skeleton once in BJS, as far as I know. You can have a skeleton with animation actions, and copyAnimationRanges to mesh with same skeleton, but no animation. This is similar to Dad72, but he is coming from 3Dsmax. It does not export to ranges, I believe. gryff 1 Quote Link to comment Share on other sites More sharing options...
csganja Posted January 21, 2017 Author Share Posted January 21, 2017 I've read the documentation some time ago... Just had the retarded idea to import the animations over the existing model [in blender] then delete then animation and export to babylon. It works like this, i have no idea what is happening. [the mesh already had the same skeleton as the animation but without animation (at least that's what i thought), maybe missing bones?( not my models)] Edit: Any quick solution to merge meshes with different materials? or any workaround? from ducumentation: arrayOfMeshes - An array of Meshes. They should all be of the same material. Quote Link to comment Share on other sites More sharing options...
aWeirdo Posted January 21, 2017 Share Posted January 21, 2017 @csganja If you can find the proper vertice indexes, using multi-materials might be a solution;https://www.eternalcoding.com/?p=283 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.