Hi:
I am totally new to shading and came across a problem I cant find an answer to on a google search. In Pic 1, you can see an unwanted cross effect in my shader. I am using a projector with a custom shader (Linked below) with a cookie and a fall off (linked Below).
the cookie and fall off are photoshop files and are texture type : Advanced in unity. The floor are 4x4 unit prefabs, marked by the black lines.
Pic 1
Cookie Left and Fall Off right
Shader Code
Shader "Projector/Hover Over" {
Properties {
_Color ("Main Color", Color) = (1,0.5,0.5,1)
_ShadowTex ("Cookie", 2D) = "" { TexGen ObjectLinear }
_FalloffTex ("FallOff", 2D) = "" { TexGen ObjectLinear }
}
Subshader {
Pass {
ZWrite off
Fog { Color (1, 1, 1) }
ColorMask RGB
Blend One One
SetTexture [_ShadowTex] {
constantColor [_Color]
combine texture * constant, ONE - texture
Matrix [_Projector]
}
SetTexture [_FalloffTex] {
constantColor (0,0,0,0)
combine previous lerp (texture) constant
Matrix [_ProjectorClip]
}
}
}
}
james