I'm quite new to the whole 3D software development, but not new to Java programming.
So heres the question:
I made a 3D Model with blender. Its a animated ginger bread man. I'm successfully loaded him into the engine and I can see him. Now I want to animate him. the point is that I animated him in blender and I want to use that animation. Unfortunately I cant work out how this works. I want to programme some kind of that way:
load(object);//thats done
animate(object);//here is the problem
I hope I could clearfie what I mean. Thx
Currently MD5 would probably be your best bet for animated models, check the Wiki and these forums for MD5 examples.
Here’s the link: http://www.jmonkeyengine.com/wiki/doku.php?id=exporting_animated_.md5_models_from_blender
There are a couple of MD5 readers out there that people are working on, however the one I use is the kproject md5loader (a bit outdated, but seems to work well), Option 1 in the wiki.
thanks a lot for the quick answers, I think the MD5 method sounds well. Can I maybe have some code for the animation?
EDIT:
I got the MD5 reader loaded and working. Unfortunally Im still busy trying to load a modell and animating it…heres my code:
MD5Mesh md5Mesh = new MD5Mesh();
MD5Skeleton md5skeleton;// = new MD5Skeleton();
MD5Animation md5Animation = new MD5Animation();
MD5AnimationReader md5AnimationReader = new MD5AnimationReader();
MD5Reader md5Reader = new MD5Reader();
MD5Model modell = new MD5Model();
//InputStream AnimInput = getClass().getResourceAsStream("aaa.md5anim");
//InputStream MeshInput = getClass().getResourceAsStream("aaa.md5mesh");
modell=md5Reader.readMeshFile("aaa.md5mesh");
md5Animation=md5AnimationReader.readAnimFile("aaa.md5anim");
md5skeleton = new MD5Skeleton();
md5skeleton=modell.getSkeleton();
this.rootNode.attachChild(md5skeleton);
the problem is that I dont know how to link the things together in the way that I can attach them to the root node. Maybe some1 could give me a hint where the problem is.