• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

How to change the transparent colour from black to red so that the outline shader will use a different colour?

jakaloy

Member
The default transparent colour in sprite editor is black with alpha 0. I'm using the Shaun Spaldings outline shader, which takes the alpha values of the adjacent texels and then draws itself with the transparent colour (black) if one of the adjacent texels has the alpha larger than 0. So if the transparent colour is black its gonna draw a black outline and if it's red, its gonna draw a red outline. The problem is, that I can't change the transparent colour from 000000 (black) to FF0000 (red). Is there any way to do this? Can I change the outline colour somehow else?
 

NightFrost

Member
I don't know the shader, but it should be easy enough to change it from adjusting just the alpha to adjusting both alpha and the red channel. (That is, you'd set the red component of the color vec4 to 1.)
 
Top