Interfaces > Core Interfaces > medit |
The medit Core Interface is available for Texture maps and Materials and exposes the Material Editor slots to MAXScript.
This method returns the material currently selected in one of the 24 sample slots of the Material Editor.
This method allows you to set the active material slot, where
The first (index) argument is the material slot index, range from 1 to 24.
The second (boolean) argument controls whether to update the slot contents or not.
This method returns the index of the active material slot.
This method allows you to put the specified material to the specified material editor slot, where
The first argument is the material to put in the editor's slot.
The second argument is the index of the material slot you wish to put the material into.
This method returns a pointer to the material base from the slot specified by the argument.
Before assigning material to scene, call this method to avoid duplicate names.
Available in 3ds Max 4 and higher.
It makes sure the Materials Editor slots correctly reflect which materials are used in the scene, which are used by selected objects, etc. This is used internally for the drag-and-drop of materials to nodes -- there is no reason why a developer should need to call it.