- Home /
Combine two ETC textures with custom shader (one with alpha)
Im trying to create a custom shader that allows me to take one RGB texture and combine it with another RGB texture that has the alpha in the G channel. I think I've managed to code my shader correctly, but how do I create an image with alpha in the G channel?
"RGB texture that has the alpha in the G channel"
it's imposible to create texture with alpha on G channel ;) paste your code here (or part), i'll help you manage that problem
Hi chris 5. Did you accomplish to do this? I want to do the same thing as you tried. Would it be possible to share the code for the shader?
Storing the alpha in the G-channel should be accomplished by using some graphics program like photoshop.
Answer by equalsequals · Jul 05, 2011 at 02:48 PM
I have posted an answer here that has a cg shader which takes the RGB of one texture and uses the red channel of a second texture as an alpha mask. You'd simply have to change the Mask.x to Mask.y as the 4th float.
Cheers
==