Texture strange behavior

Hi, I’m testing normalMaps and I have a strange behavior. If you could tell me what happens here you’d help me a lot :smiley:

So I have this 2 png’s

When I import them with an OgreXML and a material:


Material My Material : Common/MatDefs/Light/Lighting.j3md {

MaterialParameters {

m_SpecularMap : org/shipgame/test/planetoide.png

m_Shininess : 8

m_NormalMap : org/shipgame/test/planetoideN.png

m_DiffuseMap : org/shipgame/test/planetoide.png

m_UseMaterialColors : true

m_Ambient : 0.0 0.0 0.0 1.0

m_Diffuse : 1.0 1.0 1.0 1.0

m_Specular : 1.0 1.0 1.0 1.0



I get this

Do anyone knows what happens here? Thanks :slight_smile:

For the normal map the texture coordinates have to be correct. The sphere from jme3 probably doesnt have the texture coordinates this map was made for.

I exported it from blender with OgreXML. I observed the OgreExporter didn’t write the “tangent” tag inside vertexes, instead of this it writes 2 uvmap tags per vertex that have the same U and V params. What are the correct exporter options? Do you have to do something special in blender so the exporter behaves correctly?


I dont know. For this particular map you will need the sphere it was made for. I cant see if this is a normal map for some “typical” sphere form, maybe blender can create a sphere that works with this map.

mmhh isn’t that the famous TangentBinormalGenerator case?

try that


or you can use advanced binary conversion to j3o with JMP and check the generate tangent check box.

if it doesn’t change anything, in blender select your object, go to edit mode, press ctrl+N, click on calculate normals outside.

Then re-export and tell us what it looks like please.

Thanks! TangentBinormalGenerator was like magic.

This is the result (The textures aren’t the ones at the first post)

Thanks a lot :slight_smile: