8
$\begingroup$

I have defined a color palette using the ColorRamp node, and I would like to generate a random texture with those colors. What is the best way of doing this?

I'm new to blender, so please explain like I'm five years old.

Here's what I have:

Here's my input

Here's what I want:

Here's the output I want

$\endgroup$
10
$\begingroup$

You can get good results with a single Voronoi Texture

  1. Set Randomness to 0
  2. Plug the Color Output to your ColorRamp
  3. Set ColorRamp to linear (since the edges are already defined)

enter image description here


Edit:

To keep the corner aligned: offset and scale the texture using The Mapping Node

enter image description here

Or offset the UV coordinates by 1 / ( 2 * scale)
Thanks to @Gorgious for providing the formula.

enter image description here

$\endgroup$
7
  • 3
    $\begingroup$ You need to apply the scale of your object (Object > Apply > Scale) and UV-unwrap it (in edit mode, with all faces selected, go to UV > Smart UV Project) $\endgroup$
    – Gorgious
    Oct 14 '20 at 6:30
  • 2
    $\begingroup$ Is it possible to offset the bottom left corner here? i.stack.imgur.com/szvhy.gif $\endgroup$ Oct 14 '20 at 8:53
  • 2
    $\begingroup$ This could be a different question but : Offset the uv coordinates by 1 / ( 2 * scale) to get a voronoi texture with the botright corner of a square at 0, 0, 0. imgur.com/a/0P7YRMw $\endgroup$
    – Gorgious
    Oct 14 '20 at 9:38
  • 2
    $\begingroup$ @Gorgious I found that you can simply scale it using the Mapping node, and it keeps the offset. But thanks anyway, I couldn't pinpoint the relation between scale and offset :). $\endgroup$ Oct 14 '20 at 9:43
  • 2
    $\begingroup$ @JachymMichal Oh right, that is simpler indeed :) $\endgroup$
    – Gorgious
    Oct 14 '20 at 11:21

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.