drawing a circle

You probably know this by reading the subject to the thread, but I am new to opengl, glu, and glut.

Drawing a triangle, polygon, etc. is very straight forward, and I was hoping that would be the case with the circle.

My question is simple…is there an easy way to draw a circle (ie. give the x coordinate, the y coordinate, and the radius).

Any help would be greatly appreciated…

hope this helps.

float radius = 2; // change this
glBegin(GL_LINE_STRIP) // or whatever you want
    glVertex2f( radius*sin(i),radius*cos(i) );

or alternatively you could try gluDisk. This is a glu quadric so it might be a bit hard to understand on first look, but it’s easy afterwards.

Thank you for your help…