Basic X-File animation?

Goragoth

Regular
I need to do some very basic animation with .x files for a uni project. We are coding in C# but a C++ example would also be helpful. All the examples that I have been able to find talk about using skinning but we really don't need that, just frame based mesh animation is fine but there doesn't seem to be anything on it anywhere. I had a look at the mesh viewer source but that is quite complicated and we have about 4 days left to finish this so I need a quick solution. Loading .x files is really simple and I had hoped that basic animation would also be very easy with D3DX.

So then my question is: has anyone done this sort of thing and can point me to a tutorial or basic example of how it is done? :?
 
You can just parse the file and just multiply/apply the bones matrix with the mesh and output the result to what ever mesh animation format requirement for your project. That's probably your only option if you don't create the .x files your self.

Though if you're creating the .x files yourself from DCC, might as well create your own exporter instead of parsing it, its really simple and quick normally, if you don't have a robust requirement.

A Quick Solution I can think of, If you still want to use .x files with mesh animation, in your DCC, create copies of your mesh in their different poses, and export them all, ie your scene to .x file and when you're drawing just cycle through the different meshes.

Good luck.
 
Back
Top