This script utilizes new EffectID property of the VrayMaterials in Vray 2.0 and creates MultiMatte render elements for the all or for the selected objects' Vray materials and assigns proper values to their Effects ID property.
Small update to support Vray 3+.
I just noticed that I've never uploaded 0.8 version, so this version includes 0.8 updates and Vray3 support. Other thing is that I don't remember what was the 0.8 imrovements :)
MultiMatte render element now formed of user prefix + material name + _number. May have 1-3 material name in one render element, depending on color channel selection. Number part is optional, if disabled then, in case when scene contains materials with same name, render element output name collisions are possible.
Thanks to Jaimie Forrester (UK London) for suggestions - http://www.scriptspot.com/users/j-forrester
Since the version 2.0 VRay renderer's VrayMaterial contains new option - "Effect ID" - for assigning more than 16 Effects ID-s.
This script utilizes this new property and creates MultiMatte render elements for the all or for the selected objects' Vray materials and assigns proper values to their Effects ID property.
Current version of the script works ( finds VrayMaterials within these materials, in other words ) with composite materials listed below:
- Shell Material
Some works well some does not, but it's mostly of material restrictions. Multimaterial and TopBottom materials work as expected.
Vray composite materials don't work as expected and if someone knows how to show that materials in Effects Channel please let me know.
As usual - run downloaded script with Maxscript -> Run Script command from any folder on your hard drive. Resulting command 'AutoMultiMatte' will be availlable in 'Sergo Pogosyan' category.
Run script, select the material scope (selected or whole scene) and hit "Create Elements". Render.
In some cases set the starting number of Effect ID-s for selected materials and name prefix for the autogenerated render elements. This info will be stored in INI file.