How To Load a Material? [Not The Tutorial Code]

What “it”? You probably set some switch “UV” to on and still look at a model that is having a projected texture or so.

Can you link the tutorial that has this information about UV textures?

https://wiki.jmonkeyengine.org/legacy/doku.php/jme3:external:blender

From what I could understand from that tuto…collage of pictures, was what I have already done. I’ve UV mapped it in jMonkey and when I load it, it is placed improperly on the head of the model.

@normen said: First get acquainted with how jme3 handles loading models, then ask questions about input streams for special loaders, how about it? Else you are prone to misunderstand, completely not understand or right out annoy/get annoyed by people.

yew

i am sorry to annoy you but i am not mean it。
i think if load bytes model ,must add function to the lwjgl level or to the jogl level ,and add function to jme class。

@ravenocean said: yew

i am sorry to annoy you but i am not mean it。
i think if load bytes model ,must add function to the lwjgl level or to the jogl level ,and add function to jme class。

You can register custom loaders. You should a) learn more about JME so that you can ask more informed questions (do some tutorials maybe). b) stop hijacking threads with unrelated questions.

@Rukiryo said: From what I could understand from that tuto...collage of pictures, was what I have already done. I've UV mapped it in jMonkey and when I load it, it is placed improperly on the head of the model.
Just do whats outlined in the tutorial. Step. By. Step. You are noobing around for a few days now, start to focus and read.

I gotta admit that I stopped being a total noob when I decided to read everything I could before asking questions :slight_smile:

Got it. I’ll read up on it. And I swear, you’ll see my game in the near future.
Our game will reach over 1000 sales, and you’ll see it on YouTube in many playthroughs.
I don’t know how to explain it, it just will. I know what a game needs.

@Rukiryo said: I know about the tutorial code, but it doesn't show how to apply a .material file. I want to load a mesh, assign a .material file, and then apply a texture. Loading a mesh will do this automatically, but I have many different textures I want to apply, for face customization. Any ideas?

Wow…this is the … um… third thread I’ve read over the past few days that has 1 thing in common (past not reading the tutorials). A complete misunderstanding of how Material (the class) differs from the .material file generated the OGRE exporter, as well as, how textures are actually applied to a meshes.

ALL of this is covered in the tutorials.

The frustration you are hearing from people answering your questions is this:

  1. In the top menu of this site, there is a link that reads “DOCUMENTATION”
  2. Under this there is a link named “TUTORIALS & DOCS”
  3. On this page EVERY question you want answers for is explained in very simple terms, with very simple examples.
  4. You keep hearing the same thing over and over and over and over and over: READ THE TUTORIALS.
  5. From your continued questions, it is obvious that you have not gone through even the beginner’s tutorials.

Seriously need to consider doing this… I would suggest more than once. I find myself going back through them every month or so just to refresh my memory–as you won’t use every topic covered right off the bat, but eventually… you’ll run across something and say… oh yeah… I vaguely remember that… it was in tutorial 5 under the advanced section. And you won’t need to wait for someones response (which was already provided for you in the TUTORIALS)

1 Like
@normen said: The material format of jme3 is .j3m The files you have are ogre material files and of not much use for jme apart from referencing textures. Create a new .j3m material via the File menu (make sure you place it in the projects assets and not in its sources).

I saw this in other places too, but there is no option “Material” or “j3m” file when you do
File -> New File…

You simply go to “other” (the last entry), and then material in the dialog box which opens.