I’m working as part of an internet game-making team. I’ve been told to hand over the models that I have done as Directx files. The problem is that when I export meshes from Blender, the armatures that I have applied to the meshes are not included.
I do not know anything about programming python scripts, so I dont know how to make a plugin, nor do I dont understand how to use any of the plugins that I’ve found in other threads on this website. It may have something to do with how the armatures are applied to the meshes. As of now, the armatures are modifiers of the meshes.
At this point, I have not even been able to verify that it is possible to export bones in .x files, however, if it is, I would greatly appreciate some guidance on the matter.
Thank you.
Andy
Parent the mesh to the armature(Ctrl+P)
The mesh is already a child of the armature.
Apply the armature the old way(not as a modifier).
Select mesh,and Armature ----Ctrl+P----Make Parent To:
Armature.Assign vertex groups etc…
It’s still not exporting the armature.
I deleted the Armature Modifier and added the armature as a parent. The vertices in the mesh were already in groups corresponding to the armature, so I did not have to reassign them. I selected both the mesh and the armature and selected File>Export>Directx(.x). The options were selected as follows: Anim(off), Flip norm(off), Swap zy(off), Flip z(on), Speed(off), Bi.normals(on), recalc.no(off), no smooth(off). To export, I selected “Export Sel”. The armature is working great in Blender, but is just not exporting.
Perhaps I need to upgrade my Directx exporter. Could this be the case, and if so, where would be the best place to find the most current Directx exporter (or, at least, one that suits my needs)?
Thank you.
Andy
“Export Sel” works only for meshes.You have to to select
“Export All” to get the armature in the .x file
Ben - perhaps the buttons could use renaming or change the tooltips to make that more clear?
LetterRip
yes,you’re right!Just added some more info in the
documentation and corrected here
http://xoomer.alice.it/glabro1/DirectXExporter241.py
I tried using “Export all”. It still did not have the desired effect. Perhaps my version of the exporter is too old. As far as the new info in the documentation: Will this help me? What is it? and How do I use it?
Thanks a lot for your help.
Andy
You are too generic!What do you mean with the desired effect?
What are trying to export?
There are four examples in my site…
http://xoomer.alice.it/glabro1/index.html
…take a look of them and get the last exporter.
Ok,
I went to your website and copied the latest Directx Exporter script. I loaded it in Blender and Exported my model, but to no avail. When I imported the new Directx version of the model, the armature was missing. All that was in the Directx file was the mesh of the original model.
I downloaded the four examples on your website. I exported the models and armatures in Examples 1 and 2 with your latest script, but to no avail. When I opened the Exported files, the armatures were missing, as usual. I then tried importing the already-exported Directx files from Examples 1 and 2 on your website, but the armatures were missing when I imported the files.
By the way, my objective is to export a Blender file to a Directx file. The Blender file contains an Armature and the mesh that it manipulates. It is the Mesh and its Bones that I want to export, but the Bones just are not exporting with the mesh.
My version is Blender 2.42a
Thank you.
Andy
I just redownloaded(to be sure) the first example(women)…
exported the file and tried it with Mview(DX SDK) and Deep Explo.
It contains the mesh and the armature exported correctly.
I still cannot import the armature in Blender. By the way, what is the difference between the files “woman.x” and “woman1.x”?
What are the programs that you are saying you were able to open the Directx file armatures in? (“Mview(DX SDK) and Deep Explo.”) Perhaps I should try using one of these programs to open the files instead of trying to use Blender.
Thanks for your help.
Andy
hi,
I think I understand the issue - the importer support for Blender with Direct X isn’t as complete as the export support. So you won’t get necessarily the same result from importing as you did from exporting.
LetterRip
That makes sense but, given this new information, do you have any suggestions of programs that I can use to import Directx files that include bones, or am I out of luck?
Perhaps a more important question is: Is there any hope of an updated Directx importer (for Blender) being released in the future?
Thank you.
Andy
I’m having a similar problem with the Blender DirectX exporter. I can create a mesh and armature and export them, but it seems that only the root bone of the armature gets exported (though the animations for all bones get exported, oddly enough). To demonstrate the problem here is a zip file containing the .blend, the exported .x and the script I used to export it: http://fee.magickalrealm.com/ProblemFiles.zip
Help would be greatly appreciated!
P.S. I’m using Blender version 2.42
In DirectX file format every vertex must be assigned to a vertex
group(bone).The vertices at the base of the your mesh doesnt
take part of any group.
Ben,
might want to add a check for that and a warning…
LetterRip
Excellent! I added the base vertices to the group “Bone1” and it exported and imported into my game perfectly. Thanks for the help and the great script Ben!
Hi there!
I was planning to export .x from Blender, and experimented with you’re example female file. But when I export all, Blender crashes on me. when I only export sel, the mesh is exported but is almost completely black… I dunno what to do:no: