Hey guys, not sure if someone can help me out with this, but I got 2 shaders, one that blends 2 textures by the vertex alpha information and one that modulates the vertex RGB values into the texture.
I was wondering if someone can help me trying to do both desired effects together so I have vertex RGB still modulating and A channel of the mesh doing the texture blending.
Here’s the 2 shaders:
Shader "Blend 2 by Vertex Alpha" {
Properties
{
_MainTex ("Texture 1 (vertex A = white)", 2D) = ""
_Texture2 ("Texture 2 (vertex A = black)", 2D) = ""
}
SubShader
{
BindChannels
{
Bind "vertex", vertex
Bind "color", color
Bind "texcoord", texcoord
}
Pass
{
SetTexture [_MainTex]
SetTexture [_Texture2] {
combine previous lerp(primary) texture
}
}
}
}
Shader "Vertex Color Unlit" {
Properties {
_Color ("Color", Color) = (1,1,1,1)
_MainTex ("Texture", 2D) = "white" {}
}
Category {
//AlphaTest Greater 0.5
Tags { "Queue"="Geometry" }
Lighting Off
BindChannels {
Bind "Color", color
Bind "Vertex", vertex
Bind "TexCoord", texcoord
}
// ---- Dual texture cards
SubShader {
Pass {
SetTexture [_MainTex] {
combine texture * primary
}
SetTexture [_MainTex] {
constantColor [_Color]
combine previous lerp (previous) constant DOUBLE
}
SetTexture [_Texture2] {
combine previous lerp(primary) texture
}
}
}
}