5
$\begingroup$

Given a number of dupligroups, is there a way to get a unique random value for each one in a cycles shader?

Using the object info node won't work, as each instance consists of multiple objects. I'd like the value to be the same for all objects in the group (in this example, the pedestals ought to be the same as the corresponding Suzanne).

enter image description here

Here's a demo file:

If possible, I'd like to do this without joining objects or de-instantiating the dupligroups.

$\endgroup$
1
  • $\begingroup$ I have run into this issue before, never found a solution. Was wondering again today if a solution exists. Sounds like a good feature request. $\endgroup$ Commented Feb 27, 2018 at 0:39

1 Answer 1

1
$\begingroup$

Using Particles as host for DupliGroup

Thus we can use cool feature of mesh-emitter called From Dupli. This means duplis will inherit location of corresponding space on UV map.

  • Create emitter mesh and unwrap all faces of emitter as separate islands (avoid overlapping in order to have unique values)
  • Add PS system, so amount of particles is equal to face count (disable emit random, even distribution and set particle/face ratio to 1)
  • Choose Whole group as source for duplicating

enter image description here

$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .