Blender: How to Loop an Image Sequence into Textures

Animating Blender Textures With Processing

Animated textures in Blender is a thing! Immediately after finding that out, I set out to script a grid crawler texture in Processing. Because no one in their right mind would want to draw that by hand.

A Bit Of Everything has a post with the logic for a static grid, but somehow getting an animated version ate 3 hours of my life. All in all, it took about 12 tries. What I love  about Processing is that even bad guesses can have pleasing results.


This thing below. That’s all I wanted. Animated grid lines. Wierdly satisfying, right?

Grid Crawler Texture

The script is actually not that complicated. It can be done with three variables, a while loop, and a for loop.

The Processing Code

Couple things to note here. Setting the X or Y increment to a higher number will give you a more spaced apart grid. Also, you have to update the file path. Using the variable i will ensure that Processing doesn’t save over the same image over and over again.

int x = 0;
int y = 0;
int i = 0;

void setup(){
size(700, 700);
stroke(0, 0, 0);

void draw() {
for (int x=0; x<701; x=x+50){
line(x, 0, x, y);
line(0, y, x, y);
save("C:\\Users\\Desktop\\Test" + str(i) + ".png");

How to Add the Texture in Blender

The images need to be numbered sequentially for this to work. Start off by adding your object. Unwrap it and assign it a new material.Then go into the Node Editor and add an image texture.

Step 1

In the image texture node, click Open. Navigate to the folder that contains the images you want to use, highlight them all, and click Open Image.

Step 2

If all has gone well, you should now see a fifth box set to “Image Sequence.” Below that, you’ll see the number of frames you have loaded. And that’s it. Hit play. Watch it move.

A Blender Scene

8 Replies to “Blender: How to Loop an Image Sequence into Textures”

    1. I’ve got BIG plans for more Blender tutorials! I’ve been on hiatus for a wedding/vacation, but I’ll be back in October. I’ll keep an eye out for your 3D models–I love seeing what other people are doing in Blender 😀

      Liked by 1 person

Leave a Reply to gifguide2code Cancel reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

%d bloggers like this: