Loading objects problem

Hi there… again.

I have a problem in loading obj files with mtl. I saw from http://hub.jmonkeyengine.org/groups/development-discussion-jme3/forum/topic/jme3-can-now-load-obj-models-with-materials that possibility. I paste from tutorial some code, modified it with my own obj and mtl and the result was something weird. I have good experience in Java, but I’m new in jME. I’m writing my course work and thought that I’ll load some models, apply some code on them and all things will be done, but it was not so easy.



26.09.2010 17:06:51 com.jme3.util.TangentBinormalGenerator processTriangleData

WARNING: Binormal is flipped for vertex 256.



Referring to forums the last thing that I do, but I don’t have much time. Please give me a hand in the basics. I liked jME and want to write some serious projects after university, course work is the good opportunity to learn it. I wanted to paste my screenshot from an application to show the problem, but I’m not usual in forums, and simply don’t know how to do this. Thanks for reply.

Not all options available in blender are suitable for live rendering, you should only use UV textures and the basic material parameters like shininess etc. Procedural textures, particles, displacement maps etc. all wont be exported or will yield funny results.

The error you posted, when does it occur? When just importing the model? Or did you try using the TangentBinormalGenerator on the model?



Cheers,

Normen

Well simple way to post a picture:

  1. upload anywhere like imageshack ect
  2. get the direct link to it (if you open it in browser it only shows the picture nothing else)
  3. in your post write [IMG]linkhere[IMG]and you are done

Or just use the newly added “attach files” feature of the forum :wink: (below post button)

I’ve downloaded nightly build and now it is rendering good. Loading problem was before I read this topic, may be becouse of this? But still a warning “WARNING: Binormal is flipped for vertex …” didn’t disappear. I’ve tried

[java]

TangentBinormalGenerator.generate(sphere);

[/java]

but it gives an exception

[java]

SEVERE: Uncaught exception thrown in Thread[LWJGL Renderer Thread,5,main]

java.lang.NullPointerException

at com.jme3.util.TangentBinormalGenerator.processTriangles(TangentBinormalGenerator.java:113)

at com.jme3.util.TangentBinormalGenerator.generate(TangentBinormalGenerator.java:96)

at com.jme3.util.TangentBinormalGenerator.generate(TangentBinormalGenerator.java:81)

at com.jme3.util.TangentBinormalGenerator.generate(TangentBinormalGenerator.java:76)

at com.jme3.util.TangentBinormalGenerator.generate(TangentBinormalGenerator.java:72)

at initial.Initial.simpleInitApp(Initial.java:45)

at com.jme3.app.SimpleApplication.initialize(SimpleApplication.java:155)

at com.jme3.system.lwjgl.LwjglAbstractDisplay.initInThread(LwjglAbstractDisplay.java:102)

at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:151)

at java.lang.Thread.run(Unknown Source)

[/java]

Then I tried to launch TestTangentGen and had the same “WARNING: Binormal is flipped for vertex …”.