Missing texture OBJ file product with BLENDER


I have any problem when i imported a file product with blender in JME.

I exported this file in obj format and file .mth.

The object is loaded in a scene of the game but the texture missing, i saw in the web but i not able to solve this problem.

The exception is:

13-apr-2010 20.35.35 com.jme.util.TextureManager loadImage

AVVERTENZA: loadImage(URL file, boolean flipped): defaultTexture used

java.io.FileNotFoundException: C:Documents and SettingsMIcheleworkspacejmeMATTONI-MURI—104.JPG (Impossibile trovare il file specificato)

i have insert into folder C:Documents and SettingsMIcheleworkspacejme the file Mattoni-Muri—104.jpg

but the message error is equals.

I apologize for grammatical errors.

Waiting for your advice MIchele Castriotta


protected void simpleInitGame() {
        TextureState ts = display.getRenderer().createTextureState();
       URL model=HelloModelLoading.class.getClassLoader().getResource("jmetest/data/model/a.obj");

          FormatConverter converter=new ObjToJme();
          Texture baseMap = TextureManager.loadTexture(TestNormalmap.class.getClassLoader().getResource(
          "jmetest/data/images/pav14.bmp"), Texture.MinificationFilter.Trilinear,
          ts.setTexture(baseMap, 0);
          ByteArrayOutputStream BO=new ByteArrayOutputStream();
          try {
              converter.convert(model.openStream(), BO);
              Node maggie=(Node)BinaryImporter.getInstance().load(new ByteArrayInputStream(BO.toByteArray()));
              try {
                      new SimpleResourceLocator(Test.class.getClassLoader().getResource("jmetest/data/model/")));
             } catch (URISyntaxException e) {
                // TODO Auto-generated catch block
          } catch (IOException e) { 
              logger.logp(Level.SEVERE, this.getClass().toString(),
                      "simpleInitGame()", "Exception", e);

In the code you posted you didn't include ant reference to the JPG file you mention. I would suggest to first place the file in a directory that has no spaces (not Documents and Settings) and with a simpler name and see if it can find it then. It is most likely a little problem with the path.

You might want to check that you are using relative paths in the image editor in Blender. There's an option in Blender:

File/External Data/Make all Paths Relative

… that will make all references in the .blend file relative. Then just make sure the .obj has the same relative relationship to the texture that the .blend file has.

Hope that helps.


i run to your raccomandations but i don't have resolved my problem.

I havo exported from blender a file .obj who representing a romm with 3 walls, the center of the room i have imported a desk.

I applied a texture on the left wall, and another texture at the floor.

But when i load a ogj file in JME, it applied a texture on the desk.

Can you help me???

Michele Castriotta

perhaps try opening the obj / mtl file in a text editor and check the paths.