I tried to assign different random colors to instances based on this answer, but for some reason each triangle of my instancer mesh produces different color for the instances.
It seems like eachEach face triangle of the mesh is producing different results. If using a ColorRamp it's easy to see that the position on the ramp gradient varies greatly from one tri to another. Ideally, the ColorRamp gradient position should fall randomly for each instance, with an equal likelihood of landing anywhere between values 0.0
and 1.0
.
Here's another example, with different mesh geometry, different Density Max value, and a standard grayscale ColorRamp (Emission Shader is used in this example, these are not shadows):
Why is this happening, and how can I get the distribution of my random colors to be uniform? Thanks.