chronozphere
02-05-2009, 07:13 PM
Hey guys
I'm trying to render some geometry and I want to edges to look good. It now looks like this:
http://img9.imageshack.us/img9/6043/opengllines.jpg
You can see the black pixels near the lines. How to make this look better?
I use the following settings:
glEnable(GL_LINE_SMOOTH);
glHint(GL_LINE_SMOOTH_HINT, GL_NICEST);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
glEnable(GL_BLEND);
glEnable(GL_DEPTH_TEST);
glDepthFunc(GL_LEQUAL);
//My lines are a little thicker
glLineWidth(2);
I allready figured that disabling depth testing solved the problem but I rather don't do that, because I don't want to see any lines located behind other geometry.
Can someone help?
Thanks in advance. :)
I'm trying to render some geometry and I want to edges to look good. It now looks like this:
http://img9.imageshack.us/img9/6043/opengllines.jpg
You can see the black pixels near the lines. How to make this look better?
I use the following settings:
glEnable(GL_LINE_SMOOTH);
glHint(GL_LINE_SMOOTH_HINT, GL_NICEST);
glBlendFunc(GL_SRC_ALPHA, GL_ONE_MINUS_SRC_ALPHA);
glEnable(GL_BLEND);
glEnable(GL_DEPTH_TEST);
glDepthFunc(GL_LEQUAL);
//My lines are a little thicker
glLineWidth(2);
I allready figured that disabling depth testing solved the problem but I rather don't do that, because I don't want to see any lines located behind other geometry.
Can someone help?
Thanks in advance. :)