- Home /
Assigning a texture to a black & white "alpha mask"
I have a 2D texture with black and white areas (like a cow). I want the white areas to be covered with a specific texture, and the black ones to be transparent.
Saving the b&w texture into the alpha channel of the other texture and using a transparent/diffuse shader is not an option, because the black and white texture is procedurally generated in Unity (the layout of the black and white areas is never the same).
Can you guys point me to the right direction?
Thanks.
Answer by DominoOne · Feb 17, 2015 at 12:05 PM
Hello jesta,
I know that the question is pretty old and was also answered by lodendsg, but maybe this will help even more. Since a lot of people are having this problem, and won't achieve much flexibility even if they make their own shader, we've made a plugin that provides a very easy-to-use way to handle Alpha Masks. You can check it out here:
Hope it helps!
Answer by lodendsg · Jan 19, 2014 at 06:57 PM
An old question but keep showing up on my google search on the subject finally found the answer here
http://forum.unity3d.com/threads/181605-Alpha-Mask-shader-Help
Posting for those who like me ran into this post first.