Light Function, multiple textures switch on/off

Hi there,

I’m quite a rookie in the Materials creation. Anyway I’m trying to have a light with shadow shapes in it. I can achieve that with Light Functions. What I’d like to do, is to have up to let’s say 4 different shapes. Those may be all active and overlapping, or only 2 might be “active” or even none. Now, how can I (using a material instance I guess) tell the material show this one texture but don’t show that other ones. Do I have to multiply the tex with 0 or 1 to switch on and off?

On a side note, would it be more performing to have hidden, shadow casting geometry in front of the light or using the above Light Function?

Thank you.

you can use LinearInterpolate in material. Using it with 0 will show 1st texture, 1 - 2nd.

Few Lerps with few alpha parameters allows you to interpolate between them.

Or you can use simple Add node.

thanks mate. I’ll try it out today. That’s what I’m planning to do. Lerp a texture with alpha parameter. Then add it to the next (lerped) texture. If I get it right this way I can set the alpha param to 0 or 1 for each texture and achieve showing or not.