Click to See Complete Forum and Search --> : GluDisk in MS VC++6.0 & glTranslate problem


September 8th, 1999, 06:09 PM
I have a cube and I want to draw a circle around each vertex of the node. I'm trying to do:
glPushMatrix();
glMatrixMode(GL_MODELVIEW);
glLoadIdentity();
glTranslatef(vertex->x,vertex->y,vertex->z);
GLUquadricObj* glObj =gluNewQuadric();
gluQuadricDrawStyle(glObj,GLU_LINE);
gluDisk(glObj,0.999,1.0,8,1);
gluDeleteQuadric(glObj);
glPopMatrix();

Whats happening is that the circle doesnt seem to be drawn at the vertex. Its drawn at origin.
The help for gluDisk states that it is always drawn on the z=0 plane. But isnt the glTranslatef supposed to take
care of that.

Any ideas as to why this's happening. Also, if there's another easier method to do this, please let me know.

Thanks.
SR

September 8th, 1999, 11:58 PM
Yous should get rid of glLoadIdentity(), try again , good luck!