What's wrong with my .x files?

Blitz3D Forums/Blitz3D Beginners Area/What's wrong with my .x files?

SkyCube(Posted 2007) [#1]
Hello all,

I am really frustrated about this: I animate my .x files, using skeleton animation, but when I play them in Blitz3d, the animation doesn't play. It is a simple object modeled in gameSpaceLight. Can anyone shed any light on why this might happen?


GfK(Posted 2007) [#2]
Blitz doesn't support boned/animated .x format meshes.

You'll need to export them to .b3d format.


SkyCube(Posted 2007) [#3]
Hi again and thanks for your reply,

But, I have seen examples of animated .x files in Blitz, like the dolphin example and the robotic example, both included with Blitz3D. How is it possible that these can move? What about .3ds format? That one doesn't support boned animation either? What is good .x to .b3d converter?


puki(Posted 2007) [#4]
There are different versions of .X files

.3DS should be fine.

Most people here use MilkShape and/or Ultimate Unwrap.


GfK(Posted 2007) [#5]
um, .3ds format doesn't support bones/animation either.

Milkshape can export .b3d format, but not import. UU3D can import AND export, I believe.


SkyCube(Posted 2007) [#6]
I don't get it, before Blitz supported .b3d format and MD2, what did people use to create animation in Blitz? I mean, weren't these two formats added later? I supposed .x files could be animated, even if not by using skeletons.

Also, I am currently trying out Milkshape, but I've heard it is a "low-polygon modeler". What is the max polygon number this app can handle?


puki(Posted 2007) [#7]
Do you need boned animation though?

.3DS files that are already designed with animation are fine in Blitz3D.

The DarkMatter models work in Blitz - they are animated .X files - but not boned - they animate fine in Blitz.

The character animation people in my sig supply their meshes in .b3d, .3ds and .X formats.

It really depends on your needs.


Matty(Posted 2007) [#8]
Milkshape will handle models with up to 30,000 polygons usually before it complains - it won't crash it just won't load them. 8000 which is pretty high poly (I think, but then i haven't played or seen any realtime 3d stuff for a while), it can handle fine on a single model.

You can always try and see how many polygons it can handle by subdividing a grid or a cube until it falls over.


Dreamora(Posted 2007) [#9]
3DS: Only transformation of static objects (scale, move, rotate)
X: Mesh deformation of objects (no bones or vertex weights)

B3D: Mesh deformation with bones and vertex weights

MD2: just the deformation information. If you don't need actual bones, this is what you might use.


SkyCube(Posted 2007) [#10]
Thanks for the info everyone,

The thing is, I am creating a character that needs a walk animation (because I am hard-headed, I don't want to use pre-made stuff like DarkMatter).

Ok, so neither .x or MD2 support bones. B3D is the best choice for bones, apparently. Because I can't produce .b3d files with the software I actually own (don't want to buy milkshape until I have resolved these issues), I should use .x or MD2.

It seems that, without bones, such an animation as a walk animation will be very difficult to create: having to select every single vertex and then moving them to the appropiate position seems like a lot of work. How then, would I go about animating an MD2 or .x mesh? Aren't there helper tools for this?

Again, thanks for the info.


Dreamora(Posted 2007) [#11]
No you are missunderstanding I think :-)

1. Nobody said you can't use bones in your animation app, you just can't use them within B3D to animate your object in code (rag doll physics for example)

2. X has bones (thought I mentioned differently), but they don't animate your mesh if you change them in code. But you still could use them for attaching objects I think.

3. Thats the most important: Even thought MD2 does not support bones, it seems to be the by far fastest model format (with mesh deformation animation). B3D with bones and vertex weights is the by far slowest, the more bones you have the worse it gets, as everything is done on CPU.


SkyCube(Posted 2007) [#12]
Thanks Dreamora,

1. Don't worry, I just want my humanoid model to walk (I'm really a newbie at this, so rag doll physics is waaaay beyond me).

2. I don't know how to change animation in code. I was thinking on delving into this if I was unable to animate using an app. But it got me wondering that my boned .x files don't play in Blitz, which was what caused me to post my original question.

3. There seem to be mixed opinions on the MD2 format across the forums, some say it's fast, others say it's old. I will have to try it myself.


I was able to use MilkShape (demo version) and got a animated .b3d to play in Blitz, but I will try to export to .x and .md2 and see how those work.


Dreamora(Posted 2007) [#13]
MD2 in fact is old. But old does not mean bad. There are just some features missing for current stuff (no bones -> no physics and attaching stuff to the actor gets harder as you do not have bones which you can use as mount points. You would need to manually transform the mount points with your object or have a second object you parent to it which in the end is only the mount point animation (this could even be done as 3DS))


Animating in code: Bones are childs like other objects as well :) so you can easily rotate them. (don't scale them, this will give unexpected and normally quite bad results. Moving is a little pointless unless you want to tear them apart :) )


Gabriel(Posted 2007) [#14]
I know Dreamora is trying to be helpful, so I'll try to be kind, but much of what he's told you is wrong.

The version of the X format Blitz can load does NOT have bones. If it did they WOULD animate your mesh if you changed them in code. Since they're not there, you CANNOT attach objects to them. You would have to use an exporter which converts bones to geometry and hide the geometry in order to achieve that.

Furthermore, the version of the X format that Blitz loads does NOT support mesh deformation of any kind. It supports the same hierarchical transformation of objects as 3DS.

I'm not 100% certain on what I'm about to say, but I'm pretty certain that there are no versions of the X format which support any kind of mesh deformation, I think even the most recent versions just use bones, but perhaps it is possible and I just haven't come across it.


SkyCube(Posted 2007) [#15]
Hi Gabriel,

I suspected .x support on blitz has no bones (loading an animated/boned .x in blitz and having it NOT move kinda tipped me to that (no sarcasm intented)). But I think you might be wrong on some of what you said.

I don't understand what is meant by hierarchichal animation, but there are animated .x examples included with Blitz3D, they are in the samples directory in the installation. I imported one into my modeling app and it seemed that animation was achieved by vertex translation. I don't know it this qualifies as mesh deformation.

As for .x not supporting bones at all, I believe it can. I exported a boned .x from my app, and looked at it in Notepad (.x is really a text format) and there was bone information within it. The animation didn't play in Blitz, though.


Ricky Smith(Posted 2007) [#16]
it seems thee is still confusion about the .x file format and what Blitz3d supports in this aspect.
First off there are different versions of the animated .x file.
Blitz3d only supports animated .x files up to DirectX version 7. This format uses mesh hierarchy to create the animation exactly the same way that the .3ds does. Each part or limb of the body is a seperate mesh the leg will be a child of the body - the foot is a child of the leg etc. To create the illusion of movement each "limb" can be translated or scaled in relation to its parent.
An animated model could also be just one single mesh. Think of a bouncing ball or a spinning cube ! Vertices are not deformed or translated its just tranforming the pivot point of the ball to create the illusion of movement.
The .b3d format also supports this type of animation although not many people realise this - you don't always need bones if you are animating a rigid body or a mesh that is composed of various "limbs".
With DirectX version 8 the .x file format began to support skeletal animation i.e. with bones. This is the format that Blitz3d does not support - you can load the mesh but it will always be static. The .b3d format is the only format that Blitz3d can use for boned animation.

Static meshes : .3ds, .x, .b3d

Hierarchial mesh animation using seperate "limbs" - .3ds. .x(DirectX7), .b3d

Animation using vertex translation - md2

Skeletal Animation (Mesh deformation by bones) - .b3d ONLY


SkyCube(Posted 2007) [#17]
Thanks for the info Ricky Smith and thanks to everyone who replied to my original question.

I'm still surprised that formats which I think are pretty much industry standards (.3ds and .x) do not support bones.

So then, I guess b3d is the way to go. I don't intend to have a lot of things moving around onscreen, so I hope it won't slow things up too much.


Zethrax(Posted 2007) [#18]
Not sure if anyone mentioned this, but another option is to create your character out of separate parts, parent them together (using pivot entities where appropriate) and animate by rotating and moving the entities that make up the character in their parent's local space. This is how the dolphin animation you mentioned earlier was done, I believe.