Mesh (I tried to understand the difference between model and mesh but I don’t know exactly what is it):
.PSK file extension Unreal Engine Skeletal Mesh File
.MD5MESH file extension id Tech 4 3D Mesh File
.MTL file extension OBJ Material File
.tga files in the texture folder
and a .blend file that should contain everything?
I tried to convert all of them to j3o from the jMonkey IDE, but after being able to import them, there is always some problem with the texture and the models show without colors in the game.
To convert them I do the following (for example using the .blend model) :
File → Import model → select the Bulbasaur.blend file using this options:
In the next screen the model is showing up correctly, with the right textures, and there is a Bulbasaur.j3o file and a Bulbasaur.j3odata in the asset folder at the end of the import (so I assume it was successfull).
In the Textures folder however there are 2 files:
FushigidaneDh.tga for the whole body
FushigidaneEyeDh.tga for the eyes
So when I launch the game I see a creepy Bulbasaur without eyes because I don’t know how to attach multiple textures to it. Also I’m using the standard material because I don’t know it that is supposed to be inside the .blend file already.
This is the code I’m using
Spatial pokemon = assetManager.loadModel("Models/Bulbasaur/Bulbasaur.j3o");
// Using a standard material because I don't know if is included in the j3o object
Material mat_default = new Material(
//Attaching only one texture here, I need to attach another too
Can anybody help me to attach also the eyes texture to it?
Which file extensions are the best ones? Which one I should use?
How do I know if a model file contains the material too?
How do I know if a model file contains animations too?
Probably what you got was a Node with multiple Geometry objects underneath it. By calling setMaterial() on that, you blast it over all of the child geometries. One goemetry probably had one texture and another geometry the other.
And anyway, you shouldn’t have had to do that if the .blend file converted properly. And even if you did need to tweak the materials, load it into the scene composer and generate the j3m files so you can just edit them.
Is that a problem with the model itself or with the framework?
Here is the full log with FINE trace:
Additional warnings that I get in the notification tab are:
The texture Kd.001 has linear color space, but the material parameter DiffuseMap specifies no color space requirement, this may lead to unexpected behavior.
Check if the image was not set to another material parameter with a linear color space, or that you did not set the ColorSpace to Linear using texture.getImage.setColorSpace().