Jump to content

Quick Material ID frame render.


Beernardo
 Share

Recommended Posts

Hello everybody, first timer here.

 

I'm using 3dsmax 2011 and Vray 2.0. I was wondering if anybody here knows of a script that will do the following to all the materials of a scene (assuming we already converted all of the vraymtl to standards):

 

 

  • remove all maps from the material (diffuse, bump, etc)
  • make its self illumination 100
  • assign a different color to the diffuse color for each material

Every time I do a rendering I do all of this manually to sort of get a Material ID frame for easy photoshop work.

 

May be somebody knows of a faster way to do this? 3dsmax material ID element lacks of antialias so I can't use it in photoshop.

Link to comment
Share on other sites

Not in the Vray Element. The thing is that I want the colors from the materials and not from the objects. I think I found a couple of scripts that will do the trick. I'll post them after my tests.

 

This is supposed to be addressed in VRay 2 SP1. From the changelog: "VRayMtlID and VRayObjectID render elements now have an option to generate colors instead of integers for proper antialiasing;"

Link to comment
Share on other sites

With the help of two very cool scripts this is what I ended up doing, it works pretty good!:

 

1.- First I change all my vray materials to standard (to make use of the self illumination parameter later on) with the following script: http://www.scriptspot.com/3ds-max/scripts/vraymtlconverter-v2-5

 

2.- Then I used the "Modifier Modifier Zob" script (http://www.scriptspot.com/3ds-max/scripts/modifier-modifier-zorb) to randomly change the diffuse color of all of the sandard materials. This way I have a different color for each material.

 

3.- With the same script "modifier modifier zob" I assigned a 100 value to the self illumination parameter of all of the standard materials.

 

4.- Rendered the final scene turning off the maps to ignore any texture located in each material's diffuse channel. I also turned of lighting shadows etc. (you can keep displacement if you want)

 

Once you have the scripts running somewhere on your UI this process will take you no more than 5 minutes. I used to spend about an hour doing this manually. This was my final result:

 

[ATTACH=CONFIG]42749[/ATTACH]

 

 

I hope this helps somebody else

 

 

p.d. I use 3dsmax 2011 and Vray 2.0

Link to comment
Share on other sites

Also, if you want to render a wire colour from Vray without having to do a full render to get the render element, I found a way. Just tick the override material box under Global Switches, but leave the material slot empty. Sneaky... ;)

 

I've used a similar technique where I make the override material a white vray light material and then turn off indirect illumination. It works great and renders super fast.

 

E

Link to comment
Share on other sites

Thanks everybody for your input.

 

Now that I remembered I did try the VrayWireColor element but sadly it uses the wire color of each object when I really need a Material color separation to tweak each material more easily on ptohoshop and not havnig to select object by object.

Another downside to using that element is that I often use Multi/Sub-Object materials and the VrayWireColor is not going to give me the different materials selection.

 

The solution I was looking for was Material and not object dependent.

 

But I sure can think of another situations when this element will come really handy.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...