Two problems: .x animation

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
Sim-one
Posts: 2
Joined: Mon May 29, 2006 12:38 am

Two problems: .x animation

Post by Sim-one »

Hello!

Before to post this topic, I have read many topics on this forum concerning my problems, but unfortunatly I didn't found my answers... :(

My idea is load animations in the IRRlicht example TerrainRendering.

I have converted a 3ds model in .x with Panda plug-in in the same way a user tells in a previus topic.

If I place the file "dwarf.x" (embedd in IRRlicht media directory) it plays right.

If I place my file, it plays wrong... :shock: :? :? :twisted:

There are two problems:
- it doesn't play animation
- it generates a kind of "light" when I look toward it... (I have tried to change EMF_LIGHTING, EMF_NORMALIZE_NORMALS... but it's the same: a strage illumination in the area near the object)


Questions?
- what are the differents between my file and "dwarf.x" (...in your opinion...)
- Why does my object shine?

Somebody help me??? :roll:
Sim-one
Posts: 2
Joined: Mon May 29, 2006 12:38 am

Post by Sim-one »

I have upload two photos of my problems

There are two animated objects: a dwart (right object) and an aeroplane (wrog object... my object :oops: )

when I look at the aeroplane le terrain "lighting"



http://www.madley.it/withShining.jpg

when I look elsewhere the light desappears...

http://www.madley.it/withoutShining.jpg

The aeroplane generate a light when lies inside the view window...

:?:
luckymutt
Posts: 453
Joined: Sun Mar 06, 2005 11:56 pm
Location: C-Ville

Post by luckymutt »

For the "light" problem, I think it is simply not loading your textures. Make sure the textures are in the same folder as the model.

For the animations not being there...its hard to say.
First off - how did you create the animation? If you just moved the object with keyframes, it won't work. You'll need to do it with bones and physique modifier (there may be another way, but I'm not sure) and keyframe the bones.

If you are sure that it was animated properly in Max with bones and at least 2 keyframes, then post your Panda settings.
Join us in the Irrlicht chatroom:
[url]irc://irc.freenode.net/irrlicht[/url]

I love deadlines. I like the whooshing sound they make as they fly by. -D.Adams
hoffhoff
Posts: 17
Joined: Fri Mar 10, 2006 11:55 am

Post by hoffhoff »

You can generate .x files with animation on 3DS Max.
It can´t export to .x directly, but there are lots of free plugins for it.
I got one and it is working fine. If you can´t find, send me an e-mail and I can mail you my plugin.
My e-mail is:
renanguerra1@yahoo.com.br
vermeer
Posts: 2017
Joined: Wed Jan 21, 2004 3:22 pm
Contact:

Post by vermeer »

well...

max x exporter (PANDA)

http://www.andytather.co.uk/Panda/directxmax.aspx

another (XPORTER), together with a max *importer* ,also :

http://mofo.pns.to/snsp/?cmd=&mid=5
Finally making games again!
http://www.konekogames.com
vermeer
Posts: 2017
Joined: Wed Jan 21, 2004 3:22 pm
Contact:

Post by vermeer »

as luckymutt says...well, I haven't really played with irrlicht too much, but I have solved lots of probs of ppl with x format.

In most engines, just you add a bone to the airplane, apply to your airplane object skin modifier to it, asign all vertices with absolute weight of 1.0 to that bone, and generate 2 keyframes for the bone(get out of the skin link/vertex subobject level for it), ie, one in the position of frame zero, another in frame 20 position(I mean, wherever you move the airplane when it's at frame 20). Just moving the one and only bone(hitting the key icon in each frame after moving the bone, or just having previously activated the auto keyframing mode ).

You'll need to do it with bones and physique modifier (there may be another way, but I'm not sure) and keyframe the bones.
Forgive if I put something incorrect,long years since last I tested this in a Max and panda, but as much as I remember :

- you can use skin modifier,instead of physique.
- you can't use Biped. BUT...you can use it all the way, and final step be an export as FBX format, and then reimport the file (the fbx) , as it does convert biped to standard bones. Anyway, I think there's a plug to convert biped to bones... I know this way of fbx does work, but is not free possible problems. I personally don't have any, but when some popped out, I had to guess how to solve them.
-don't leave any vertex without weighting, or with not enough weighting (ie: if u have a vertex with 0.4 weight, for a bone, and 0.35 for another bone, and there are no more bones, problem here. Still 0.25 of weight lacking. In exports, that often translate to non weighted/asigned vertices... )

-previous to aplying skin modiifer, ensure your model has all vertices well welded. (weld threshold in the edit mesh or edit poly modifier roll)

-better make it all in a single mesh object, no attached objets, etc.
-better a single standard material, no multisubobject.
-use names without spaces, try to avoid "." and mostly any punctuation.
-do actually create TWO keyframes at least, or chances are wont export anything.
-check and do trial and error with panda settings. Now for max 8 there's the possibility of using an xml file for the settings, a really good thing. I haven't tested though nothing of this since max6.
There are many possibilities of you don't havning the correct settings in panda exporter.


This are all the safe tips. You can go trying more and more features, one by one, if you want, till you find a point that the engine or plugin doesn't like.So you can spot it.

x files have these issues also in blender and other softwares. And irrlicht engine tends to be a bit picky with x files. A good rule is to open and save in mview tool (check my signature) to make the x file x compliant.

I did a huge many pages thread some eons ago about Panda settings, but in the old forum I was reported to be hard to find with old froum search . I dunno now.
Finally making games again!
http://www.konekogames.com
Post Reply