View Full Version : Fading out a line

07-08-2006, 05:45 PM

Quick question. I've got a stippled line and am trying to make it so it fades out (so alpha is 1 at one end and 0 at the other). Is there a nice easy way of doing this?


07-09-2006, 03:03 AM
Setting a different alpha value at each vertex?

07-09-2006, 11:16 AM
No that just seems to make the whole thing transparent (when one vertex A=1.0, the second A=0.0). Btw Im using (GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA) as by glBlend arguments.

07-09-2006, 01:54 PM
Do you have smooth shading enabled?

07-09-2006, 02:56 PM
Yep I do.

07-09-2006, 03:19 PM
Ah no I dont, I thought I'd done so but it wasn't in my code when I checked.

Thanks for the help!.