How to set the values of gluLookAt() in order to see the entire grid from ABOVE?
This is a part of my code:
void Draw_Grid()
{
for(float i = 0; i <= 1000; i += 50)
{
glBegin(GL_LINES);
glColor3ub(150, 190, 150);
glVertex3f(0, -4, i);
glVertex3f(1000, -4, i);
glVertex3f(i, -4,1000);
glVertex3f(i, -4, 0);
glEnd();
}
}
void screen_reshape(int width, int height)
{
glViewport(0, 0, width, height);
glMatrixMode(GL_PROJECTION);
glLoadIdentity();
float ar;
ar = ((float) width)/height;
if(ar > 1.0)
glOrtho(-10,1000.0*ar,0,1000.0,-1000.0,1000.0);
else
glOrtho(-10,1000.0,0.0,1000.0/ar,-1000.0,1000.0);
.
.
.
gluLookAt(?, ?, ?,?, ?, 0, 1,0);
}