I first explain how my systems are working right now.
If you create image and add there pixels ( 0red, 0green, 255blue ) it will be invisible in game.
If i compile the image into my format, i scan the pixels.
If ( r == 0 && g == 0 && b == 255 ) a = 0 else a = 255
Now this is the code what im using to make alpha pixels invisible
glEnable(GL_ALPHA_TEST); glAlphaFunc(GL_GREATER, 0.5);
There is a problem with that. Because the fragment shader blends alpha pixels too some blue pixels will be still rendered.
If i use glAlphaFunc(GL_GREATER, 0.9) it will be fine but if you look at the pixels closer you see that the blending is sharp.
So what i now wish to do is while compiling image i replace blue pixels ( after the alpha pixels are created ).
So the image will look something like this:
If i now use that texture with glAlphaFunc(GL_GREATER, 0.5); it will be perfect.
I created this texture in photoshop. Just used blur but those pixels what wasn't (0,0,255) i did not touched.
I would be very grateful if someone can help me but i understand that this what im asking is really big things.
Sorry about my bad english.
Thank you in advance!