Home Unreal Engine

UDK Material - Vertex Paint being cancelled out by up-vector math?

This post is also on the UDK Forum here, I just REALLY need this fixed :/

I have a material that I want to go on a trench-like mesh. I need it to blend between the surface/wall textures and can do this using a Constant3Vector Dotted with a Transformed Vector, and use this as the alpha of a lerp node to blend between the two. This is simple enough and works just fine. (See the images)

However, I also want to be able to vertex-paint puddles on the surface of the trenches, for simplicities sake the following material is just blending between the regular diffuse scalars and the same scalars multiplied by a colour to give a blue tint. Now the issue is, whenever the Vector-Blend functionality is plugged into the lerp that blends between the two normal textures, the effects of the vertex colours disappear. The vertex colours ARE still there, but they are having no effect. See below:

Simple Mesh with vertex colours applied in the red channel. (Vertex Colour View)
MeshPaintApplied_zpsd2fa6b47.jpg


The vector-blending math being plugged into the 'normal' lerp causes the effect of the vertex colours to go away, even though they are still applied to the mesh.
NotWorking_zps4a10bd1c.jpg
PaintGOne_zps3f2b7db8.jpg


Using a Scalar to blend between the normal and diffuse maps works, the textures blend correctly when the mesh is rotated, and the effect of the vertex colour is shown.
Working_zps843dbc1a.jpg
BlendWorking_zpsb6d287a1.jpg


This ONLY happens when the Normals are blended. I can still blend the Diffuse maps based on the mesh orientation just fine and get my vertex colours, but the normal does not :/

Replies

Sign In or Register to comment.