Randomize texture on array

Hello everybody,

I’ve search through the internet but can’t seem to find an answer, and as I’m new to blender, I’m maybe going the wrong direction?

I have a wall made of planks in a array. I’ve added the texture to one plank, so it’s repeated to each invididual element of the array. How can I randomize the texture position so it doesn’t repeat like that? I know its possible with particules, or different objects, but can’t find a way to do it in an array, over different individual meshes

There is some variation in the picture, because I’ve move some of the texture by hand. But it’s not really efficient, nor the result is good.

Forget everything I said before. Control the UV offset on your array modifier.


You have two textures, each one with it’s own set of features, and then they are mixed together with a mask texture.

This example in the image is very basic so you can understand the idea. After that is only a matter of tweaking it a lot until you get the config you like.

  • Two image textures are used in your case.
  • They are mixed together with another image node node (not checkerboard, but anything else, even one you create in photoshop).
  • You can take the mask image and blend it together with some other type of node such as noise or wave, and that way you can get not perfect rects but something like soft and wavy rects.
  • You might create a checkerboard mask in ms paint (10x10 png) but then import it and scale it large enough so it becomes blurry.
  • You can mix up to 3 or 4 textures together, but notice that your graph is getting even more complex.

Lots of configurations to try.

1 Like

That was my first suggestion to him, then I thought that the array UV offset was more appropriated for what he was looking for, so I deleted my comment. Its a great suggestion though, of course.

@Calandro Thanks, it’s a quick and dirty trick I didn’t know, don’t know a lot yet anyway ahah, but it works even if it’s not perfect.

@const Thanks, it’s getting late here, I’ll try this tomorrow, right now it’s kind of blurry but I’ll give it a try, I’m sure it will make more sense then. If not i’ll come back to you…

Now, wanting to try Calandro’s way, I’ve stumble on a related issue I think, I did apply the array modifier on one wall, therefore, every instance is now its own mesh, or island I think you say.

In that case, is there a way to do the same kind of thing? One texture randomized over different meshes, all under one object? Looking through the nodes, I’ve seen in the geometry node, under input, that there is a “Random per island” option, but I can’t make it work…

I’ve seen a video on youtube where they do it, but across separate objects. Not across several meshes in one object. I could separate all my mesh, but lets say I have 10 walls with 50 planks, that would make 500 differents objects, seems messy and not efficient…

Thanks for your help, I appreciate it :slight_smile:

Actually, if you have applied the modifier all the pieces are together in the same object.

There’s a very simple way to make the job, but tis involves separating all parts in independent objects.

The result will be as perfect as possible.

First, transfer your object to another collection to avoid filling the one you are working with dozens of objects. Then you enter the edit mode on your mesh then go to “mesh” - “separate” - “by lose parts”.

After doing that, you are going to edit your material adding an object info node to your mapping node, this way:

That’s all. Ah, to make it easier to move all those meshes you can parent all these new objects to an empty or to any other object you think is convenient to you. If you parent it to the wall it will take any change you make to the wall itself. Position rotation and scaling.

If you don’t want to separate the mesh in lots of objects you can…

Enter edit mode in one window and in another open UV editor.

In the mesh edition mode you select face selection and go to “select” and “random”. This will select random faces of your mesh so this way you can move them in the UV editor window a bit to create some randomness.

Do this process a few times until you are satisfied with the result.

When you select random, you can adjust the values to select a bigger or smaller number of faces at the same time.

I use geometry/random per island + object info/random → 1D white noise. Sometimes random per island don’t work with bevel node (depending on smoothing options), and I may (for something that has multiple islands) use a collapsed UV → vector snap → 2D white noise. If that fails (despite snapping) because of UV smoothing, I’ll resort to collapsed UV → old fashioned 2D noise (42.5 scale, 0 detail, 0 roughness, 42.5 distortion) and use it’s fac output to drive a 1D white noise.

But in this case, do you really need geometry or can you get away with faking it on a simple plane?

If you do need geometry, and you won’t make proper use of endgrain anyways, I would just use builtin box mapping (with geometry/random per island → 1d white noise → multiply → add to object coord) and control the texture orientation using the object coordinate for the object. You may have to update the array direction.

Here an example of faking it on a plane:

Here an example of using simple box mapping and various ways you can do randomizing:

I’ve rotated the origin of the right array to get the grain in the direction I want. I’m using bevel here, but if I now activate smooth shading random per island would produce unusable (for this purpose) output.


I really loved the random per island coordinates. Never used before. Just thought that the nodes setup could be a bit simpler, so I made mine.

That setup is perfect for objects with array, applied or not. Random only works if you have many different objects involved. If I can decide, random per islands is what I wold use in this case.

About the bevel, I don’t understand what kind of problem you had. With my setup everything works fine.

Mine is not the best texture though, I just took it as an example.

Just started to wonder how easy would it be to create random wooden floors this way.

1 Like

@CarlG Thanks, I’ve tried it but it doesn’t work, so I’ve tried the simpler version of @Calandro and it doesn’t work either for me… What am I missing…? Should I tweak any value…? (stupid question)

Also @Calandro seems like your randomizing the light color right? Any way to randomize the position of the texture too that way? Well, if I manage to reproduce your setup at least…

The version of the shader setup I put only works in objects that are merged in only one mesh on in array.

If you have the mesh separated in many different objects you just change the random per island for the node “object info”, “random”.

I think that could be the problem.

And yes, the settup also randomizes the position.

Yes, as mine, as you can see, I only have one cube in my scene, it’s just an array that I didn’t apply…!

Here’s the result with object node

Oh, I see the problem here. This settup only works in Cycles and you are looking it over the EEVEE mode.

Change it to rendered view. I also had this doubt at the first time I was testing the nodes using the EEVEE viewer mode and I also doubted that it was working.

Now you change it back to the first node of the setup and view it under the rendered view mode.

Awesome thanks !!! So easy in the end, just had to know the trick ^^ I think you’ve learned it too because of @CarlG ? So I’m glad you were able to learn something because of my incompetence ahah!

Now I’m gonna experiment with it. As you said, I wonder how easy it might be with this to randomize wooden floor, different types of walls and other stuff :slight_smile:

1 Like

Yes. Oh, you can also insert a color ramp node or any other node that controls the intensity of the colors of an image to control the intensity of the multiply node. In my case the influence was softer cause my image was brighter, since yours is darker the effect can bee too strong, so you can control it using those nodes.

This way:

I like the color ramp because you can work with the colors and the intensity of them in the same node in a very intuitive way.

Thank you, I was wondering how to that :slightly_smiling_face:

An other question, can we inluence just the random position, and not the color for example?

EDIT: Nevermind, I manage to do it with the color ramp :slight_smile:

You can also study how the specific kind of wood you are working with changes depending on it’s darkness and then do this:

With that, as the wood gets darker the material chooses a different set of colors or better saying a mix of them.

The result with that:

For that you also use the “random” output as the factor of the mix.