procedural texture mixing?

I have a scene, that I was going to do via a texture animation,

but then it dawned on me how big the files would be,

is there a way to have two textures mix?

I need

Starts off “texture A”

gradually morphs into “texture B”

this would take up 98% less space… and just be more efficient in general.

I found this,

import Image

background = Image.open(“test1.png”)
foreground = Image.open(“test2.png”)

background.paste(foreground, (0, 0), foreground)
background.show()

But where would I place the Image system?

would it take a lot of cpu?

can I push it on another thread?

Please have a look at the texture tab of your mesh object.

I have, but I can’t seem to get two uv mapped textures to mix as a animation,

Is it just me?

Is it as simple as a material action?

As animation?

You can use two uv maps and animate one or both of them via Python. You can use the alpha of a texture for blending. I have not much experience in this topic. So I suggest you play a bit with that.

You might even be able to use the node editor (with GLSL indeed).

Try this http://blenderartists.org/forum/showthread.php?261926 with the 2 images in 2 planes and look this:

How about put two objects in the same position, fade one another through alpha control with object.color()?

The first idea that came up to my mind is an animated stencil map of size around 1x1px that goes from black to white smoothly and make 2 materials with the 2 textures, then in the nodes (assuming that you know the basic stencil map node setup) set white to material 1 and black to material 2.

I am afraid I can only ask questions and drop resources back to the team, as my gpu will not allow shaders,
any working solution would be great,

the thing is, this object that is retextured is going to be massive ( a whole level unto it’self)
(a large spaceship) (much of it’s details are going to be baked normal maps)

I wanted to zoom all the way in on a window and as it happens have the textures change, and as stuff gets out of frame have it be deleted from the scene (since it is switching to inside the ship anyway)

All without a single cut

Can someone take a few screens of the node setup?
or point to a tutorial?

Can someone take a few screens of the node setup?
or point to a tutorial?

I think an animated texture will not work since it would always play and not when you want.
But you could use the vertex colors or object color and change them via a python script when you want to.
They can then be accessed via nodes.
If you need help with this I will upload a .blend!

With fluppi’s method that means the “blend” could be uneven over time ?

:smiley:

I would love to see the .blend,

The node editor is a very powerful tool. And the best way to learn it is to play with it. So here’s a little model I made ages ago.
Have fun dissecting it.

I can see some of the node tree, but most appears missing, unless I am mistaken, I only see “Scene” and “Output”

Look at the material nodes rather than the scene nodes.
So select the island mesh, go to the node editor, and look for the button in the nod-editors bar that looks like the icon for materials.

Thanks Geoff :smiley:

Now, about my particular problem,

I have been messing with setups for a minute,

How do I apply a mixed RGB as a UV map?

What do you mean by a ‘mixed rgb’?

You can extract channels with the node ‘Seperate RGB’ you can mix images with the mix node, and if you feed a color channel into the ‘fac’ input on the mix node, you can make it mix only where there is a certain color.

For inputs to the material, use textures rather than images, as they allow you to specify the UV map.

I wanted to zoom all the way in on a window and as it happens have the textures change, and as stuff gets out of frame have it be deleted from the scene (since it is switching to inside the ship anyway)

Why not have 2 materials and blend them according to camera distance, a sort of texture/material LOD. Then you can have the textures you want in the materials. Nodes can do that in a small setup here
The other solutions are:
1.Have 1 texture divided in lets say 4 parts 1 with one texture type and the other with your second. Then use python to move the UV.
2. Use the nodes, set textures to RGB stencils, then use python to change the vertices color according to distance. For me the example I provided is the fastest and easier way!

This sounds like a perfect use case of LOD.

Sorry that it took me so long to do this, but here is an example of how it could be done.
One method is to use a script, the other one wich is probably more simple and efficient uses an object color animation to blend between the inputs.
The textures are represented by the RGB values in the nodes, replace them with your texture/material.

Hope that is what you where looking for!

Attachments

textureBlending.blend (517 KB)