Announcements
Autodesk Community will be read-only between April 26 and April 27 as we complete essential maintenance. We will remove this banner once completed. Thanks for your understanding

One material, multiple objects, multiple shaders ?

Neigno
Participant Participant
868 Views
3 Replies
Message 1 of 4

One material, multiple objects, multiple shaders ?

Neigno
Participant
Participant

Hi,


Is it possible to assign one material on different objects but with an unique surface shader for each object ?


I guess i'm doing something wrong with the index input from the switch shader, which node should i use ?

7674-b.jpg

Thanks.

0 Likes
869 Views
3 Replies
Replies (3)
Message 2 of 4

madsd
Advisor
Advisor

I would use 1 material, and use array maps instead, you can use the index driver from your material ID. Its quite powerful to work like that, and you can maintain sanity in very big noodles handling many color controllers.

You basically setup a single material with the index lists you need.
I dont know how you do it in c4d, but I can write an OSL shader that does it all with a single wire to a single material.

0 Likes
Message 3 of 4

peter.horvath6V6K3
Advisor
Advisor

User ID from the Arnold tag is exported as a user parameter called user_id. Instead of the utility shader, use a user_data_int shader to drive the index of the switch, with the attribute set to user_id.

0 Likes
Message 4 of 4

Neigno
Participant
Participant

Thank you so much, it works.


0 Likes