Page 1 of 1

Better material organization

Posted: Wed Feb 03, 2010 12:35 pm
by ShadeOgre
Ogre comes with plenty of useful materials / shaders, but finding / overview all is painful. I mean: Example.material has Examples/Robot which is a great sample to HW skinning, but it is at the middle of the file, and first I didn't think examples.material has it. Ok, Examples/Robot used in samples, but another examples:
- WoodPallet (in Example.material) don't even has the Examples/ prefix (and lot of materials in the file)
- Examples/ShowUV (Normal, ...): great for debug, wrote the same for myself, but I just figured out this is in the Example.material file. Not a huge work to write it, but if I has it why should I rewrite?

I would separate the material and compositor scripts as well.

The material collection should be an easily searchable and extensible one - to allow anybody to extend it for own use or to extend Ogre's core material-library. With a community like Ogre has a lot more material sample could exist if the structure is easy to understand and posting/broadcasting is simple and straightforward. I think this is a huge potential, but now it's hard to get what I'm looking for, and often I found weeks/months later a very similar material/shader I had to write in the Ogre-material-library (directory in the SDK), or in Wiki.

Re: Better material organization

Posted: Wed Feb 03, 2010 5:08 pm
by syedhs
I think this should lie with tool - you can call it Material Editor or something like that. This material editor should be able to read all folders and contents accordingly, and then categorize the resources. Categories are like material, compositor, vertex shader, fragment shader, overlay. They are all displayed in a tree view that when you double click the element, the appropriate content will be shown at the right panel. Shouldn't be too hard, but I don't see anything like it so far.

Re: Better material organization

Posted: Thu Feb 04, 2010 2:32 pm
by ShadeOgre
Would be definitely a great idea! But maybe it's a bit more complicated - list all shaders/materials/etc would be only the 1st step - it should allow to see the source of the materials / shaders, and maybe allow to edit as well. And that's a harder thing.

If somebody knows about a program like this, please share it. I don't know any, so maybe if I have the time I will start to write one.