I’d like to set a material instance parameter for every element of an array.
My use case: I’m setting the emissive color for an array of objects based on the distance to another object. Right now all elements of the array are using the same material instance. This causes all objects to have the same emissive color. But some objects are closer then others. Closer objects should have a brighter emissive color.
This is what I have by now:
Could someone please give me a hint what I’m doing wrong?