Blender 2.5 GLSL textures -- Exception when loading asset

I am getting the following error when trying to load a .blend file which uses GLSL textures (in paint mode). Any ideas on this? I did try to use ogre xml–>j3o, but this did not work either. Perhaps this texture type isn’t supported?



Jan 1, 2012 1:52:15 PM com.jme3.scene.plugins.blender.textures.TextureHelper getTextureFromImage

INFO: Reading texture from file: Dirt Stencil

Jan 1, 2012 1:52:15 PM com.jme3.app.Application handleError

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

java.lang.IllegalStateException: No loader registered for type “”

at com.jme3.asset.DesktopAssetManager.loadAsset(DesktopAssetManager.java:248)

at com.jme3.asset.DesktopAssetManager.loadTexture(DesktopAssetManager.java:325)

at com.jme3.scene.plugins.blender.textures.TextureHelper.loadTextureFromFile(TextureHelper.java:829)

at com.jme3.scene.plugins.blender.textures.TextureHelper.getTextureFromImage(TextureHelper.java:762)

at com.jme3.scene.plugins.blender.meshes.MeshHelper.toMesh(MeshHelper.java:182)

at com.jme3.scene.plugins.blender.objects.ObjectHelper.toObject(ObjectHelper.java:157)

at com.jme3.scene.plugins.blender.AbstractBlenderLoader.toObject(AbstractBlenderLoader.java:134)

at com.jme3.scene.plugins.blender.BlenderLoader.toObject(BlenderLoader.java:70)

at com.jme3.scene.plugins.blender.BlenderModelLoader.load(BlenderModelLoader.java:63)

at com.jme3.scene.plugins.blender.BlenderModelLoader.load(BlenderModelLoader.java:49)

at com.jme3.asset.DesktopAssetManager.loadAsset(DesktopAssetManager.java:273)

at com.jme3.asset.DesktopAssetManager.loadModel(DesktopAssetManager.java:408)

at com.jme3.asset.DesktopAssetManager.loadModel(DesktopAssetManager.java:418)

at mygame.FirstPersonDemo_1.simpleInitApp(FirstPersonDemo_1.java:184)

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

I doubt they are supported and in any case they would have to be baked. Read the wiki and/or one of the many online tutorials on how to create game-ready models. Basically its down to UV-mapped color/normal/specular maps.

Normen,

I was able to get a watered-down version of what I need to work when using multi-textured mode in blender instead of GLSL.

Can you tell me if texture paint mode is supported? In blender 2.5, you can utilize stencils to paint textures, from a texture stack. I haven’t found anything about this in the forums/documentation. The end result of my material file looks like the following. I am only seeing one texture from the stack in my j3o file though, not two. Let me know if you have any ideas. Thank you.



material Ground

{

receive_shadows on

technique

{

pass

{

cull_hardware none

ambient 0.800000011920929 0.800000011920929 0.800000011920929 1.0

diffuse 0.6400000190734865 0.6400000190734865 0.6400000190734865 1.0

specular 0.5 0.5 0.5 1.0 12.5

emissive 0.0 0.0 0.0 1.0

scene_blend one zero

texture_unit

{

texture tex1.jpg

tex_address_mode wrap

scale 1.0 1.0

env_map planar

colour_op_ex blend_manual src_current src_texture 0.0

}

texture_unit

{

texture Stencil.png

tex_address_mode wrap

scale 1.0 1.0

tex_coord_set 0

colour_op_ex blend_manual src_current src_texture 0.0

}

texture_unit

{

texture tex2.jpg

tex_address_mode wrap

scale 0.1 0.1

env_map planar

colour_op_ex blend_manual src_current src_texture 0.0

}

}

}

}

You can’t export stencil maps to jME from blender. jME doesn’t use stencil maps, but it uses a cooleer and similar feature, that’s aplha maps. You paint multiple textures onto your terrain in jME by using alpha maps with the Terrain Editor Plugin. There’s a way to do it via code of course, but the SDK is there to facilitate your life ;).

Ah, and I forgot to mention that you can mix until 12 textures with alpha maps in jME ;).

EDIT: Oh, actually are 11 xD.

Hey, glaucomardano. Yeah, I have made some nice terrains via jme terrain editor, but I have a couple of issues when using it in a game. I was using a blender terrain as a work around. The first issue is performance related–low FPS. Seems to be more than just LOD–because this happens even when overlaying with a low quality texture. And the other issue is related to collision–two separate collision issues actually–I could go into more detail, but I should probably open another thread.

Right, that’s clearly a separate feature. That wouldn’t work unless there is some way to consolidate the texture stack into one texture? I.e. once you are done painting your blender model with several textures + stencils, save a single master texture which is referenced in .material file. Still haven’t found a way to do this. Not sure that it exists.

If you wanna export your stencil maps from blender then the only way would adding this feature to jME xD. Maybe you can ask @kaelthas if he plans work on it some day.

You could just create the textures in blender, and the j3m material in jME, if this feature will exist of course!