Author Topic: Newest Version of OgreMax Breaks With Message:  (Read 26998 times)

Offline AGP

  • quad
  • ******
  • Posts: 1726
    • View Profile
Newest Version of OgreMax Breaks With Message:
« on: June 05, 2013, 09:53:44 pm »
Exception in thread "main" java.lang.NumberFormatException: For input string: "f
loat2"

When I replace "float2" with "1" in the xml it comes closer to loading (but breaks for lack of proper UVs).

Offline raft

  • Moderator
  • quad
  • *****
  • Posts: 1993
    • View Profile
    • http://www.aptalkarga.com
Re: Newest Version of OgreMax Breaks With Message:
« Reply #1 on: June 05, 2013, 10:06:35 pm »
always post the stack trace in case of an exception.

which 3d editor is that? maya? max?

what exactly dou you mean by lack of proper UV's? no UV's or what?

Offline AGP

  • quad
  • ******
  • Posts: 1726
    • View Profile
Re: Newest Version of OgreMax Breaks With Message:
« Reply #2 on: June 05, 2013, 10:11:30 pm »
Max 2013. Here's the stack trace. The comment about the UVs is for when I edited the XML directly and replaced "float2" with "1". Doesn't apply to this stack trace.

Exception in thread "main" java.lang.NumberFormatException: For input string: "f
loat2"
        at java.lang.NumberFormatException.forInputString(Unknown Source)
        at java.lang.Integer.parseInt(Unknown Source)
        at java.lang.Integer.parseInt(Unknown Source)
        at com.jmex.model.XMLUtil.getIntAttribute(XMLUtil.java:162)
        at com.jmex.model.ogrexml.OgreLoader.loadVertexBuffer(OgreLoader.java:34
8)
        at com.jmex.model.ogrexml.OgreLoader.loadSubmesh(OgreLoader.java:520)
        at com.jmex.model.ogrexml.OgreLoader.loadMesh(OgreLoader.java:694)
        at com.jmex.model.ogrexml.OgreLoader.loadModel(OgreLoader.java:241)
        at com.jmex.model.ogrexml.OgreLoader.loadModel(OgreLoader.java:193)
        at OgreToBones.createAnimatedGroup(OgreToBones.java:134)
        at OgreToBones.initialize(OgreToBones.java:160)
        at OgreToBones.loadModels(OgreToBones.java:256)
        at OgreToBones.<init>(OgreToBones.java:67)
        at OgreToBones.main(OgreToBones.java:337)

Offline raft

  • Moderator
  • quad
  • *****
  • Posts: 1993
    • View Profile
    • http://www.aptalkarga.com
Re: Newest Version of OgreMax Breaks With Message:
« Reply #3 on: June 05, 2013, 10:14:25 pm »
The comment about the UVs is for when I edited the XML directly and replaced "float2" with "1". Doesn't apply to this stack trace.
ok but what exactly dou you mean by lack of proper UV's? no UV's or what?

what happens when you try to open this file with OgreMax viewer?

Offline AGP

  • quad
  • ******
  • Posts: 1726
    • View Profile
Re: Newest Version of OgreMax Breaks With Message:
« Reply #4 on: June 05, 2013, 10:16:09 pm »
The file has UVs, but messing with the "float2" lines breaks them.

The binary still works. But that doesn't help with Bones.
« Last Edit: June 05, 2013, 10:19:09 pm by AGP »

Offline raft

  • Moderator
  • quad
  • *****
  • Posts: 1993
    • View Profile
    • http://www.aptalkarga.com
Re: Newest Version of OgreMax Breaks With Message:
« Reply #5 on: June 05, 2013, 10:18:40 pm »
you still didn't answer ny question.
Quote
what exactly dou you mean by lack of proper UV's? no UV's or what?

try to convert that working binary with OgreXMLConverter and see if that helps.

Offline AGP

  • quad
  • ******
  • Posts: 1726
    • View Profile
Re: Newest Version of OgreMax Breaks With Message:
« Reply #6 on: June 05, 2013, 10:33:40 pm »
In point of fact, I have answered it.

And I'm surprised to say that the product of OgreXMLConverter still didn't succesfully convert to bones. But I can tell you that the product of OgreMax 2.4.3 did (and 2.4.6 doesn't).

Offline AGP

  • quad
  • ******
  • Posts: 1726
    • View Profile
Re: Newest Version of OgreMax Breaks With Message:
« Reply #7 on: June 05, 2013, 10:34:47 pm »
That is to say, a binary generated by 2.4.6 couldn't be successfully converted into a usable XML for conversion into bones.

Offline raft

  • Moderator
  • quad
  • *****
  • Posts: 1993
    • View Profile
    • http://www.aptalkarga.com
Re: Newest Version of OgreMax Breaks With Message:
« Reply #8 on: June 05, 2013, 10:41:59 pm »
can you post or email the xml file?

Offline AGP

  • quad
  • ******
  • Posts: 1726
    • View Profile
Re: Newest Version of OgreMax Breaks With Message:
« Reply #9 on: June 05, 2013, 10:47:10 pm »
Shouldn't I send you the max, instead?

Offline raft

  • Moderator
  • quad
  • *****
  • Posts: 1993
    • View Profile
    • http://www.aptalkarga.com
Re: Newest Version of OgreMax Breaks With Message:
« Reply #10 on: June 05, 2013, 10:51:04 pm »
no, send the xml and binary file please. I have no program to open the max file.

I've sent you my email

Offline raft

  • Moderator
  • quad
  • *****
  • Posts: 1993
    • View Profile
    • http://www.aptalkarga.com
Re: Newest Version of OgreMax Breaks With Message:
« Reply #11 on: June 06, 2013, 03:06:35 am »
this looked like a flaw in the latest version of OgreMax. you converted to xml format with OgreMax right? after manually changing float2 to 2 (not 1) Bones successfully loaded the model. I dont have the texture but it seemed okey to me.

I couldn't convert to xml with OgreXMLConverter yet since my version is Ogre tools is 1.7.4 but the binary file is created with 1.8. To upgrade to 1.8 I need to upgrade my Ubuntu which will take some time.

I would suggest sticking to older version of OgreMax if there is no problem with that. also contacting with OgreMax author may help.


Offline AGP

  • quad
  • ******
  • Posts: 1726
    • View Profile
Re: Newest Version of OgreMax Breaks With Message:
« Reply #12 on: June 06, 2013, 09:00:19 am »
I've e-mailed OgreMax's Derek about this. I'll report his response, but I expect it to be something to the tune of "I can only concern myself with the people using Ogre itself." Thanks for the "2" tip, I suppose I should've tried it myself.

Offline raft

  • Moderator
  • quad
  • *****
  • Posts: 1993
    • View Profile
    • http://www.aptalkarga.com
Re: Newest Version of OgreMax Breaks With Message:
« Reply #13 on: June 06, 2013, 05:41:20 pm »
the Ninja.mesh.xml file gives the clue, that "float2" value should actually be "2" ;)

Offline AGP

  • quad
  • ******
  • Posts: 1726
    • View Profile
Re: Newest Version of OgreMax Breaks With Message:
« Reply #14 on: June 06, 2013, 08:02:58 pm »
My expectation was close enough:
"Hello,

 OgreMax 2.4.5 was updated to have its XML mesh and skeleton format to match to newest version of the Ogre3D 1.8.x release (actually, the OgreXMLConverter tool, since the Ogre3D library itself doesn't have an XML format).

 Since the newest Ogre3D 1.8.x and 1.9.x releases allows different types other than floats to be used (for example "short2"), it would make more sense to adjust your software to support either "2" or "float2" since this is how all the Ogre3D versions are going to work.

 -Derek"

My response was to ask him for a backwards-compatibility option. The alternative for us I think would be to manually edit the XML parser. I'll post his second response, though.