First of all: Merry Christmas.
I am having two Problems right now with jMe:
- When I import a .blend file, I need to put it into another folder, so that the links to the Textures are not correct and jMe asks me for the right path. He then copies all textures to the projects assets (the root directory of the model in the assets).
-> When I don’t do it, the scene remains untextured, because he assumes that that path would be in assets? Is that a bug in jme?
-> When I do it, it copies the textures into the model root, even when I select some files already in the assets. That works for now but due to redundancy it would be nice to remap textures. Maybe some external .j3o Editor would do, where I could manually edit the texture path?
- When I use UV-Mapping in Blender and have the vertices out of the image range (to stretch the image), jme goes crazy and only shows some small part texturized
for 2. you need to set the texture to repeat.
@nehon: Thanks a ton! Unfortunately I am still struggeling with the “Spatial-Tree” traversing and setting the Texturemode.
But: If I didn’t rely on “Repeat-Only”, is there no built-in method used in jMonkey?
I mean I verified, that Blender states that Material/Texture as “Repeat”, I don’t know what went wrong. Doesn’t the jMe Material File save that Information?
Is there maybe a Debug-Tool to manually edit .j3o Files, so I could try that? (Like a “Compile-Time” setting of the right texture Wrap Mode?
Thanks in Advance
Edit: Actually I can’t use that, because
Geometry.getMaterial().getTextureParam(“ColorMap”) == null;
Tbh I don’t know how the blender loader does its materials. maybe @kaelthas could tell you more about this issue.
What I know though, is that you can load your j3o file in the scene composer and generate a new material for a geometry. Select the geom, in the properties panel, you’ll have a material drop-down box. open it and select the first entry “create a j3m file”. It will create a material in /Materials/generated/nameofthej3o.j3m, and assign it to the geometry.
In this j3m file, you can control the path to the texture, and the repeat mode (a check box in the j3m editor).
That said…you’d have to do this for all your models, and it might not be acceptable depending on the number of materials you may have in your assets.
If you are having problems with paths, simply store the texture inside the blend file
As for texturing I could tell you a bit more if you uploaded the model and post a link here.
Hey @Kaelthas (Still chilling at the magisters’ terrace? ;))
Is that possible? I always did the following:
“link them with blender” → used j3’s Model Importer → manually choose missing Textures → they got added into my assets folder (even if they already were there).
Now the only problem I “see” with your & my method is:
If I used the same texture over and over again, I would have a large redundancy.
For that, it would be nice to have all Textures load off either the .jar’s Assets/ or maybe even a local file path (that makes patches decrease in size).
My Main Problem did solve though I mapped the bottom side of the object and wondered why the top side is looking oddly… Such a shame.
Coming back to the main problem: As I think about supplying a xml/json/whatever file to be parsed whilst loading the model, I think about specifing the texture-path there which however seems to be a bit complicated (regarding uv and what not)
Can’t I use something like absolute paths ("…/Textures/Wood1.png")?
Using the OGRE exporter I could do that, but using the Blender Importer doesn’t let me do that.
Is there sort of an j3o “decompiler” which simply decompiles everything? Or something like an j3o Editor as Third-Party-Tool available here?
(Sorry for the many questions )