|
| Using in-active map slots in a standard material. |
Betic |
I am trying to use one of the in-active map slots in a standard blinn material. I can enable it and set the bitmap, but I cannot make it Active, nor can I set the name. I can get the name with this getSubTexmapSlotName() but I am unable to set the name at all. I kinda figure I would have to set this up in the Standar Material settings. Is that available to get and edit? I would love to make all standar Blinn materials have one extra slot down there for custom use.
read 166 times 9/1/2010 9:21:03 PM (last edit: 9/1/2010 9:21:03 PM)
|
Betic |
if any of you want to see an example, highlight a blank material in the material edit and use these:
mat = medit.GetCurMtl()
mat.maps[15] = Bitmaptexture fileName:"ENTER PATH TO BITMAP HERE"
now you will see this appear in the 15th in-active slot down, but I have not found a way to make it active nor have I found a way to assign it a name.
To view the name and an example, use this:
getSubTexmapSlotName mat.maps[15]
example: getSubTexmapSlotName mat.maps[2]
Notice the diffuse color name matches whats there in the maps list. I am going to guess right now the only way I am going to be able to do this is do a scripted plugin material that basically copies the entire standard material but activates one of those slots, but I still havn't found out how to do that either.
I would rather have a way to just throw in a callback on maxstartup that enables this slot in every standard material. I do not want to have to change the material from standard to a custom standard just for this one extra slot.
read 156 times 9/1/2010 10:20:26 PM (last edit: 9/1/2010 10:20:26 PM)
|
|
|