hemicube
12-05-2007, 06:10 AM
Ok, so I'm getting these really strange gaps within a single line-strip. I've never seen this happen before and I've done my share of OpenGL/GFX programming.
My graphics card is an ATI mobility x1400 running on Vista :S
My actual application is drawing lots of fairly tessellated B-Splines, but right around where the tangent on the spline is close to pi/2 I get these annoying gaps!!
I thought it might have something to do with my tessellation code but it's really impossible to get a gap within a single LINE_STRIP prim... Here are some pics of the problem and a small code clip that exhibits the same problem, just as a sanity check! :)
1:1 no scaling of any sort.
http://hemicube.googlepages.com/normal.jpg
Zoomed in quite a bit to get a clear view of that lovely gap.
http://hemicube.googlepages.com/scaled.jpg
glBegin(GL_LINE_STRIP);
for (u32 i = 0; i < 32; i++)
{
f32 t = (f32)i / (32.0f - 1.0f);
f32 x = cosf(t*kPi)*4.0f;
f32 y = sinf(t*kPi)*4.0f;
glVertex2f(x, y);
}
glEnd();
Any insight on this would be awesome as I'm getting ready for another release of my app and this is kinda holding me back...
P.S. I've tried the same code under Linux as well with the same results.
Chris
__
My graphics card is an ATI mobility x1400 running on Vista :S
My actual application is drawing lots of fairly tessellated B-Splines, but right around where the tangent on the spline is close to pi/2 I get these annoying gaps!!
I thought it might have something to do with my tessellation code but it's really impossible to get a gap within a single LINE_STRIP prim... Here are some pics of the problem and a small code clip that exhibits the same problem, just as a sanity check! :)
1:1 no scaling of any sort.
http://hemicube.googlepages.com/normal.jpg
Zoomed in quite a bit to get a clear view of that lovely gap.
http://hemicube.googlepages.com/scaled.jpg
glBegin(GL_LINE_STRIP);
for (u32 i = 0; i < 32; i++)
{
f32 t = (f32)i / (32.0f - 1.0f);
f32 x = cosf(t*kPi)*4.0f;
f32 y = sinf(t*kPi)*4.0f;
glVertex2f(x, y);
}
glEnd();
Any insight on this would be awesome as I'm getting ready for another release of my app and this is kinda holding me back...
P.S. I've tried the same code under Linux as well with the same results.
Chris
__