Repeat texture on different meshes of different sizes

Cloning creates a new JS object (so it uses some memory, but rather small). The image data is reused without cloning.

If you want to dynamically modify the number of repeat-s, DO NOT clone the texture every time. Cloning is done only once, then you can freely change the repeat of each material’s texture.

I will prepare an example with UV.

Edit: here is the example with UV modification (the size changes every second, only one texture is used):

https://codepen.io/boytchev/full/wvYeMrG

image

Edit 2: I also modified my previous example (the one with 6 cloned textures) – now it has dynamically changed size too

2 Likes