Help Please - About Models in jme

download OgreCommandLineTools, just google for it, then drag you .mesh or .skeleton to proper executable file and voila.

Ok thanks, i have .xml, but i still have the import error :S

hello there, listen to me, how is the syntax to convert .mesh to .xml? because have many lines of command, and i use default  but in the class testmeshloading.java i have error in the line:

if (clone.getControllerCount() < 1)

                    throw new IllegalStateException(

                            "Ninja's animations are missing");

and i have animation in my character, can someone please give me the syntax command to convert .mesh to .xml

pleeeasseeeee

thanks for everything

leonardotr11 said:

hello there, listen to me, how is the syntax to convert .mesh to .xml? because have many lines of command, and i use default  but in the class testmeshloading.java i have error in the line:
if (clone.getControllerCount() < 1)
                    throw new IllegalStateException(
                            "Ninja's animations are missing");
and i have animation in my character, can someone please give me the syntax command to convert .mesh to .xml
pleeeasseeeee
thanks for everything


Pay attention to what Henri told you.
Ref http://www.ogre3d.org/download/tools.

ok i did it, but i get the same error:



SEVERE: Exception in game loop

java.lang.IllegalStateException: Ninja's animations are missing

        at jmetest.ogrexml.TestMeshLoading.simpleInitGame(TestMeshLoading.java:203)

        at com.jme.app.BaseSimpleGame.initGame(BaseSimpleGame.java:544)

        at com.jme.app.BaseGame.start(BaseGame.java:74)

        at jmetest.ogrexml.TestMeshLoading.main(TestMeshLoading.java:81)

11/05/2009 18:55:21 com.jme.app.BaseSimpleGame cleanup

INFO: Cleaning up resources.



in this line:



if (clone.getControllerCount() < 1)

                    throw new IllegalStateException(

                            "Ninja's animations are missing");



and i have exported the animation from the ogremax, hey i need just drag the skeleton or the mesh? don't need the both?

thanks

I can't use OgreMax, to export .mesh .xml ?

I dont understand anymore what your problem is. Did u use the ogrocommandlinetools after using ogremax? Just describe exactly what you are doing from the beginning.

ok i create a character in 3dstudio max, after i add a Biped(skeleton), after i set the skeleton animations and what part of character each bone will pick to move, after i have used ogremax to export Ogre scene, than i have box01.mesh,box01.skeleton,box01.scene,box01.material, ok i used OgreXMLConverter, i drag box01.mesh and box01.skeleton in the executable, ok now i have box01.mesh.xml and box01.skeleton.xml, but i try to use my xml files in the class TestMeshLoading, but the IDE say "Animation missing".

thats it

leonardotr11 said:

ok i create a character in 3dstudio max, after i add a Biped(skeleton), after i set the skeleton animations and what part of character each bone will pick to move, after i have used ogremax to export Ogre scene, than i have box01.mesh,box01.skeleton,box01.scene,box01.material, ok i used OgreXMLConverter, i drag box01.mesh and box01.skeleton in the executable, ok now i have box01.mesh.xml and box01.skeleton.xml, but i try to use my xml files in the class TestMeshLoading, but the IDE say "Animation missing".
thats it


TestMeshLoading is not a tool or utility that loads any *.mesh.xml, *.skeleton.xml, *scene*.xml.  It is an example/demo made to load the ninja sample files... that should have been pretty clear by the error message saying that Ninja's animations were missing.

Why don't you work through the tutorial at http://www.jmonkeyengine.com/wiki/doku.php?id=blender_ogrexml_tutorial?  It explains how you can use a generic tool to test your exports, and also how to then load them into your own app... it does not say to use the unmodified TestMeshLoading class to load your exports.

ok, so you think i should use blender or ogremax?

and how i can transform .scene in .scene.xml because ogrelinecommands dosen't work

leonardotr11 said:

ok, so you think i should use blender or ogremax?

At the time when I wrote the importer, I only had access to Blender3D so I couldn't test the importer with files exported from OgreMax. However you should be able to load these files fine. If you are having issues with any files, try to upload them somewhere and I could take a look at what's wrong. Since I currently am preoccupied with other matters I might not have time to make the necessary fixes though.

leonardotr11 said:

how i can transform .scene in .scene.xml because ogrelinecommands dosen't work

The .scene format is an XML format by nature and has no binary equivelant. You should be able to load any dotScene files with the SceneLoader.
leonardotr11 said:

ok, so you think i should use blender or ogremax?

I don't really care.

You already have the XML files, so skip past the "export" part of the tutorial if you are satisfied with what you have.


and how i can transform .scene in .scene.xml because ogreCommandLineTools doesn't work


Based on what you have said before, I don't necessarily believe that ogrecommandline doesn't work, but you could try to hand edit the scene files.  You can also do an awful lot by just loading *.mesh.xml files, including animation and texturing.  See if you can read the available documents about it, like everybody else does.

The plugin for 3ds max can export it to xml directly, there is a check box to set it to do so.

ok ok but , here i don't have a check box to export directly Oo please show me how, because just export-> Ogre Scene, don't appear any check box :S

more one thing, thats my xml file of skeleton:



<skeleton>

    <bones>

        <bone id="0" name="Bip01 L Foot">

            <position x="112.693" y="-1.90735e-006" z="0" />

            <rotation angle="0.110115">

                <axis x="0.0050055" y="0.977774" z="-0.209603" />

            </rotation>

            <scale x="1" y="1" z="1" />

        </bone>

        <bone id="1" name="Bip01 L Calf">

            <position x="108.306" y="9.53674e-007" z="0" />

            <rotation angle="0.151863">

                <axis x="-1.25429e-009" y="-1" z="-2.78702e-008" />

            </rotation>

            <scale x="1" y="1" z="1" />

        </bone>

        <bone id="2" name="Bip01 R Calf">

            <position x="113.466" y="-1.90735e-006" z="0" />

            <rotation angle="0.240804">

                <axis x="-9.39457e-010" y="-1" z="3.08787e-009" />

            </rotation>

            <scale x="1" y="1" z="1" />

        </bone>

        <bone id="3" name="Bip01 L Thigh">

            <position x="-18.9657" y="21.9253" z="-0.0266745" />

            <rotation angle="3.16455">

                <axis x="-0.0224923" y="-0.00114652" z="0.999746" />

            </rotation>

            <scale x="1" y="1" z="1" />

        </bone>

        <bone id="4" name="Bip01 Pelvis">

            <position x="-14.3858" y="252.847" z="5.38111" />

            <rotation angle="3.14159">

                <axis x="0.707106" y="0.707107" z="-9.74996e-007" />

            </rotation>

            <scale x="1" y="1" z="1" />

        </bone>

        <bone id="5" name="Bip01 Spine">

            <position x="18.9657" y="2.64645e-005" z="0.0116217" />

            <rotation angle="0.000690534">

                <axis x="-0.00522516" y="0.999985" z="0.00174218" />

            </rotation>

            <scale x="1" y="1" z="1" />

        </bone>

        <bone id="6" name="Bip01 Spine1">

            <position x="14.6097" y="-2.38419e-007" z="0.0116333" />

            <rotation angle="0">

                <axis x="1" y="0" z="0" />

            </rotation>

        </bone>

        <bone id="7" name="Bip01 Spine2">

            <position x="14.6098" y="0" z="0.0116334" />

            <rotation angle="0">

                <axis x="1" y="0" z="0" />

            </rotation>

        </bone>

        <bone id="8" name="Bip01 Spine3">

            <position x="14.6097" y="0" z="0.0116333" />

            <rotation angle="0">

                <axis x="1" y="0" z="0" />

            </rotation>

        </bone>

        <bone id="9" name="Bip01 Spine4">

            <position x="14.6097" y="0" z="0.0116334" />

            <rotation angle="0">

                <axis x="1" y="0" z="0" />

            </rotation>

        </bone>

        <bone id="10" name="Bip01 Spine5">

            <position x="14.6097" y="0" z="0.0116333" />

            <rotation angle="0">

                <axis x="1" y="0" z="0" />

            </rotation>

        </bone>

        <bone id="11" name="Bip01 Neck">

            <position x="14.6054" y="-7.62939e-006" z="5.44156" />

            <rotation angle="0">

                <axis x="1" y="0" z="0" />

            </rotation>

        </bone>

        <bone id="12" name="Bip01 L Clavicle">

            <position x="0.00430298" y="7.47012" z="-5.44154" />

            <rotation angle="3.14103">

                <axis x="0.707107" y="0.707107" z="0.000282522" />

            </rotation>

        </bone>

        <bone id="13" name="Bip01 L UpperArm">

            <position x="28.5028" y="0" z="-1.49012e-008" />

            <rotation angle="0.141847">

                <axis x="0.707518" y="0.640372" z="-0.298901" />

            </rotation>

            <scale x="1" y="1" z="1" />

        </bone>

        <bone id="14" name="Bip01 Head">

            <position x="43.5457" y="9.05991e-006" z="-6.57588" />

            <rotation angle="0.000690534">

                <axis x="-2.13788e-010" y="-1" z="-2.76878e-006" />

            </rotation>

        </bone>

        <bone id="15" name="Bip01 L Forearm">

            <position x="76.8606" y="3.05176e-005" z="0" />

            <rotation angle="0.105096">

                <axis x="3.7835e-010" y="-1" z="-7.19346e-009" />

            </rotation>

            <scale x="1" y="1" z="1" />

        </bone>

        <bone id="16" name="Bip01 R Foot">

            <position x="114.979" y="1.90735e-006" z="0" />

            <rotation angle="0.158172">

                <axis x="0.00478772" y="0.98507" z="0.172086" />

            </rotation>

            <scale x="1" y="1" z="1" />

        </bone>

        <bone id="17" name="Bip01 R Thigh">

            <position x="-18.9657" y="-21.9253" z="-0.0267961" />

            <rotation angle="3.11451">

                <axis x="-0.0428766" y="0.0012508" z="0.99908" />

            </rotation>

            <scale x="1" y="1" z="1" />

        </bone>

        <bone id="18" name="Bip01 R Clavicle">

            <position x="0.00430298" y="-7.47011" z="-5.44158" />

            <rotation angle="3.14103">

                <axis x="-0.707107" y="0.707107" z="-0.00028056" />

            </rotation>

        </bone>

        <bone id="19" name="Bip01 R UpperArm">

            <position x="28.5028" y="0" z="1.49012e-008" />

            <rotation angle="0.081122">

                <axis x="-0.71976" y="0.372652" z="0.585727" />

            </rotation>

            <scale x="1" y="1" z="1" />

        </bone>

        <bone id="20" name="Bip01 R Forearm">

            <position x="72.8087" y="0" z="-1.90735e-006" />

            <rotation angle="0.000690534">

                <axis x="-3.11219e-006" y="-1" z="-7.79371e-007" />

            </rotation>

            <scale x="1" y="1" z="1" />

        </bone>

    </bones>

    <bonehierarchy>

        <boneparent bone="Bip01 L Foot" parent="Bip01 L Calf" />

        <boneparent bone="Bip01 L Calf" parent="Bip01 L Thigh" />

        <boneparent bone="Bip01 R Calf" parent="Bip01 R Thigh" />

        <boneparent bone="Bip01 L Thigh" parent="Bip01 Spine" />

        <boneparent bone="Bip01 Spine" parent="Bip01 Pelvis" />

        <boneparent bone="Bip01 Spine1" parent="Bip01 Spine" />

        <boneparent bone="Bip01 Spine2" parent="Bip01 Spine1" />

        <boneparent bone="Bip01 Spine3" parent="Bip01 Spine2" />

        <boneparent bone="Bip01 Spine4" parent="Bip01 Spine3" />

        <boneparent bone="Bip01 Spine5" parent="Bip01 Spine4" />

        <boneparent bone="Bip01 Neck" parent="Bip01 Spine5" />

        <boneparent bone="Bip01 L Clavicle" parent="Bip01 Neck" />

        <boneparent bone="Bip01 L UpperArm" parent="Bip01 L Clavicle" />

        <boneparent bone="Bip01 Head" parent="Bip01 Neck" />

        <boneparent bone="Bip01 L Forearm" parent="Bip01 L UpperArm" />

        <boneparent bone="Bip01 R Foot" parent="Bip01 R Calf" />

        <boneparent bone="Bip01 R Thigh" parent="Bip01 Spine" />

        <boneparent bone="Bip01 R Clavicle" parent="Bip01 Neck" />

        <boneparent bone="Bip01 R UpperArm" parent="Bip01 R Clavicle" />

        <boneparent bone="Bip01 R Forearm" parent="Bip01 R UpperArm" />

    </bonehierarchy>

    <animations />

</skeleton>



is correct?

ok look i found ogremax options in the 3d studio max, now can someone tell me what i have config in scene options and object options to my animation work?

thanks a lot people (:

hey guys, look :



SEVERE: Exception in game loop

java.nio.BufferUnderflowException

        at java.nio.Buffer.nextGetIndex(Buffer.java:474)

        at java.nio.DirectFloatBufferU.get(DirectFloatBufferU.java:205)

        at com.jmex.model.ogrexml.anim.MeshAnimationController.softwareSkinUpdate(MeshAnimationController.java:335)

        at com.jmex.model.ogrexml.anim.MeshAnimationController.update(MeshAnimationController.java:440)

        at com.jme.scene.Spatial.updateWorldData(Spatial.java:541)

        at com.jme.scene.Node.updateWorldData(Node.java:383)

        at com.jme.scene.Spatial.updateGeometricState(Spatial.java:517)

        at com.jme.scene.Node.updateWorldData(Node.java:395)

        at com.jme.scene.Spatial.updateGeometricState(Spatial.java:517)

        at jmetest.ogrexml.TestMeshLoading.simpleInitGame(TestMeshLoading.java:216)

        at com.jme.app.BaseSimpleGame.initGame(BaseSimpleGame.java:544)

        at com.jme.app.BaseGame.start(BaseGame.java:74)

        at jmetest.ogrexml.TestMeshLoading.main(TestMeshLoading.java:81)



My error :b



In attach have my skeleton file,

please can someone help me, i need so much make the character move

Yeah I know I got the same errors I think, that's why I was forced to move to md5. U can try setting all the vertex weights to 1 i read that it helped somebody but it didnt help me.



Oh and it seems that u used biped for your animation I'm not sure if that might also be the issue. Just try making 1 box in 3dsmax and make 1 bone to move it, it worked for me with ogre xml, but when I tried 2 bones I failed. I dont know if I might have had more than 1 rootbones and that was the issue

hamm, dammit  :frowning:

so Henri you can tell me how is md5? how i create, model, animate etc…

what program use?

thanks

1.My friend made me the animations with 3DsMax by using biped and IKSolver i think. (I think you use the same kind of skeleton as I saw from your bone names, but since those are just bones I hope u also have a mesh and the bones are skinned to the mesh?)

2.Then he sent me the .max files.

3.Then I used der-ton's exporting script md5exporter.ms to export (from 3dsmax)  the mesh and animation to .md5mesh and .md5anim accordingly.

4.Then I imported the animation with Neakor's MD5Importer to JME scene.