Hi,
At my office we recently upgraded from VRay 7.3 to VRay 7.4, and with this update I noticed that I am no longer able to do something that was fundamental to my workflow previously: use the VRayMtlID render element to separate each sub-shader of a VRayBlendMtl.
Previously, if I assigned a different Effect ID to each shader in a VRayBlendMtl, then the VRayMtlID render element would assign a different color to each Effect ID, thus creating a mask that allowed me to regulate each material easily in the post-production phase. However, since updating, the VRayMtlID only shows one solid color connected to the base material, and all Effect IDs of the coats above are ignored.
This is a shame because I really relied on this feature for the post-production phase, and I am not sure how to achieve this again. All I need is to be able to create a mask that separates VRayBlendMtl sub-shaders, so I can edit them individually in post-production. Are there any other render elements that I could set up to achieve this? Or any other methods at all? Any help is appreciated! Thanks!
Are you sure this worked before? Or maybe you’re confusing the VRayBlendMtl with a multi/sub-object node? What exactly is your setup? Please attach a simple scene that shows it working in 7.3 but not in 7.4, since I cannot make it work in either.
Yes, I am absolutely certain it was a VRayBlendMtl. I’ve been playing around some more since posting and actually - I figured it out! It’s surprisingly simple - just leave the Base material slot empty in your VRayBlendMtl.
I’m attaching below some screenshots of the setup and the resulting channels. It works with VRayMtlID and with the MultiMatteElement too. I apologize for the collage; since I am a new user I cannot attach more than one image. Hopefully it’s clear enough, if there’s any doubts let me know.
Material setup: no base material, and each Coat has a unique Effect ID. In this case, I made the IDs 2 (dark green material) and 3 (blue material) so they’d show up on the MultiMatteElement without changing its default setup:
Unfortunately I am not at liberty to share examples of how it worked with VRay 7.3, as the material is confidential to the studio I work for, and I no longer have the possibility to replicate an example scene with VRay 7.3.
I don’t know what the implications are of leaving this slot blank, I will admit. I’m not sure if it’s something that affects render time or causes other issues on larger scenes. With the previous method I used in VRay 7.3 (which, however, didn’t require this “hack”) I didn’t have any issues, though.
I’d share the 3DS Max scene too but I’m not sure how (it’s my first time posting on the forum).
Glad you’ve found the culprit. No need to unplug the basemtl; you just need to turn off the Effect ID of the Base mtl (or set its Effect ID to 0). This would yield an integer of 0 in the MatID pass, though. It works the same way in 7.3.
EDIT: FYI, I logged the issue (VMAX-15719).