How to generate more than one random number in Blender

This is a tutorial on how to generate more than one random number in Blender. To generate a single random number in Blender you use the Object Info node and out pops a random number for each object with a value between 0 and 1. If you connect this random number to a Color Ramp node, roughly half of the balls will be red and the other half will be black. 

But what if you want half of the balls to be rough and the other half to be shiny - independent of color. If you use the same random number again in another Color Ramp node you will realize to your horrors that all black balls are shiny and all red balls are rough. 


To generate another random number you need to use the first random number to generate a new random number. To do that you connect the random number to a Math node, set it to Add, and add some constant to the original random number. Then you connect this random-number-plus-constant into a White Noise Texture node, and now you will have a second random number different from the first. Success - not all black balls are shiny!


If you need a third random number, you can repeat the steps above but add some other large constant to the original random number. And if you need a fourth random number, you add some other constant, and if you need a fifth... you get the point!

Comments