PDA

View Full Version : Blending textures using masks.



GoSsS
11-28-2009, 10:36 AM
Hi there !

I've a problem in unreal doing a blending between two textures using an alpha mask.
Basically when you want to blend to textures together you can do that with a vertex color and 2 textures using a lerp but the result is kinda not really interesting (left side of the image below).

http://developer.valvesoftware.com/w/images/9/9c/Blendmodulate.jpg

The result I want is the right side one.
But I really don't know how to have that in UT (i tried many things but nothing work :( )
So I really need to know how to use an alpha mask where the vertex color isn't black or white instead of the crappy fade between blending textures.

I tried to do that only using the red channel of the vertex color (if the vertex color is red =1 apply texture A, if the vertex color is red=0 apply tetxure B and if vertex color red is between 0.01 and 0.99 use the alpha) but I totally failed (certainly because i'm not really familiar with the node system of UT and I don't know many nodes).

Thanks in advance.

Edit : I tried this example : http://www.hourences.com/book/tutorialsue3mated3.htm (second one) but it seems that it didn't work correctly.