Hi guys Iam new to OpenGL. Iam trying to create a small circle and would like to position it in the bottom-left corner of the screen. The code below draws a massive circle. Could you please tell me how to change the size of the circle and the position of it to a specific place on the window.
Thanks
#define PI 3.1415926535898
GLint circle_points =100;
void Circle()
{
glClear(GL_COLOR_BUFFER_BIT);
double angle = 2* PI/circle_points ;
glBegin(GL_LINE_LOOP);
double angle1=0.0;
glVertex2d( cos(0.0) , sin(0.0));
int i;
for ( i=0 ; i< circle_points ;i++)
{
printf( "angle = %f
" , angle1);
glVertex2d(cos(angle1),sin(angle1));
angle1 += angle ;
}
glEnd();
glFlush();
}