- Home /
Toon Shader gets alpha from color, not texture
Hi!
http://answers.unity3d.com/questions/30055/add-alpha-information-into-the-standard-toon-shade.html
There is answer how to add alpha color to the texture in toon shader. I did it just fine. But, I can't get my texture working with it, and texture has alpha channel. Why? For sample, here in Toony-Lighted.shader I see:
void surf (Input IN, inout SurfaceOutput o) { float4 c = tex2D(_MainTex, IN.uv_MainTex) * _Color;
...
o.Alpha = c.a;
Like, aren't this code part about getting information from texture, including alpha? Or it has to be done somewhere in the vertex shader as well?
If the texture contains alpha values they are used. In your case it is combined with _Color.a.
Your answer
Follow this Question
Related Questions
Is there a way to create an fading alpha-cutoff effect? 0 Answers
Alpha textures? -1 Answers
Explain Toon Shading Please 1 Answer
Avatar T-Shirt Color With Print 3 Answers
self illumination with alpha texture 0 Answers