0
$\begingroup$

In the compositor, there is a dedicated ID mask node where you put in the number of the mask you want, and it will output it.

We can get access to ID masks in Cycles materials via the Object Info node, but there is no dedicated ID mask node. I assume it is possible to make something similar with some combination of math nodes and group it up. Has anyone figured out the best way to handle this?

$\endgroup$
3
  • 1
    $\begingroup$ Aren't masks the product of rendering? How can you access the result of the rendering process prior to generating an image? That would be impossible and create a dependency loop. Also you can access ID Indexes in Cycles materials, not ID Masks $\endgroup$ – Duarte Farrajota Ramos Jun 30 '17 at 5:19
  • $\begingroup$ @DuarteFarrajotaRamos You are correct, I mean ID Indexes. $\endgroup$ – Ascalon Jun 30 '17 at 5:22
  • $\begingroup$ The mask from the object id is the entire object, meaning any ray that hits the object which is affected by the material you are working with. You could use a math greater/less than node to vary based on id. $\endgroup$ – sambler Jun 30 '17 at 9:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.