MAXScript Tool For Quick Matte Creation

Become a member of the CGSociety

Connect, Share, and Learn with our Large Growing CG Art Community. It's Free!

THREAD CLOSED
 
Thread Tools Search this Thread Display Modes
  06 June 2013
MAXScript Tool For Quick Matte Creation

Hello,

I just created my first MAXScript tool which allows artists to quickly create Matte render elements very quickly. The tool basically is an interface for the Render Elements section of the Render Setup dialog window and works by controlling the Object ID channels of selected objects.



The first section of the tool allows you to choose whether you want your selection of objects to be contained in one Matte pass or if you want to create one matte pass for each individual object in your selection.

The next section allows you to set all the basic parameters for the Matte pass as you would do if you were to set it up normally.

The third section gives you two options for setting the Object ID's of your selected objects; "Assign Unique ID" will look at all the objects in the scene, find the highest Object ID number and create a Matte with an ID of one more than the highest in the scene and also set your objects to have that ID too. When "Assign User-Specifed ID" is selected the "Object ID" spinner is enabled and this will allow you to set your own ID.

When the "Create Matte Render Element(s)" button is pressed all the information is put together and a Matte pass is created. Note that the file path for the Matte pass is assigned AFTER the pass is created, so you have to click on the pass to refresh it.

The "Set Selection's ID" spinner allows you to changed the ID of selected objects which can be useful if you want to add certain obejcts into a Matte pass which has already been created.

The "Select Objects With ID" spinner allows you to select objects which a specifed ID which can be helpful when checking which objects are in a specific Matte pass.

-----

Note that the naming of the render elements doesn't work well when you have the "One Per Object In Selection" option chosen because it gives all the Matte passes the same filename meaning that they save over each other and so only the last pass is saved.

This tool works with the Scanline and mental ray renderers and in 3ds Max 2008 and above. I don't have a license for VRay but I understand that VRay works with their own VRayObjectID pass.

The MacroScript will create a new category in the Customize User Interface window called "Harry's" which you might not like if you've got your own cetegory. If you do, then edit the script.

-----

Hope you enjoy it and get some use out of it, I made it in two days for a university project I'm working on over Summer, which also means that I won't be able to develop it much further, but it didn't seem to throw any errors when I was using it.

Thanks,
-Harry

-----
Attached Files
File Type: zip MatteCreator.zip (1.5 KB, 2 views)
 
  06 June 2013
Thread automatically closed

This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.
__________________
CGTalk Policy/Legalities
Note that as CGTalk Members, you agree to the terms and conditions of using this website.
 
Thread Closed share thread



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
CGSociety
Society of Digital Artists
www.cgsociety.org

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump
Miscellaneous

All times are GMT. The time now is 03:13 PM.


Powered by vBulletin
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.