title: OpenGL ground plane becoming black at certain perspectives
body: <p>I have a simple program in OpenGL that creates a ground plane, randomly placed tree objects, and has some lightning. There is an issue with the lightning that I am unable to solve. When the camera at a certain 'x' angle, the lightning seems to be not affecting the ground and it appears black. This an instant change, it does not gradually darken. Most of the ground is lit seemingly fine, but at certain angles it immediately turns black. The code is very messy and a lot of the core of it is part of the OpenGL tutorial on Lighthouse 3D because I am taking a class on OpenGL and this is the goal for the class, to take these tutorials and create something unique with it. Does anyone know how to fix this? Maybe lighting is implemented incorrectly? The code below is the code for drawing the ground plane. </p>
  
  <pre><code>// Draw ground
  glColor3f(0.039f, 0.341f, 0.078f);
  glNormal3f(1.0f, 1.0f, 1.0f);
  glBegin(GL_QUADS);
      glVertex3f(-1500.0f, -8.0f, -1500.0f);
      glVertex3f(-1500.0f, -8.0f,  1500.0f);
      glVertex3f( 1500.0f, -8.0f,  1500.0f);
      glVertex3f( 1500.0f, -8.0f, -1500.0f);
  glEnd();
  </code></pre>
  
  <p>This code is for the lighting.</p>
  
  <pre><code>glEnable(GL_DEPTH_TEST);
  glEnable(GL_CULL_FACE);
  glEnable(GL_LIGHTING);
  glEnable(GL_LIGHT0);
  glEnable(GL_LIGHT1);
  glEnable(GL_LIGHT2);
  glEnable(GL_AMBIENT);
  glEnable(GL_DIFFUSE);
  glEnable(GL_SPECULAR);
  glDisable(GL_EMISSION);
  GLfloat lightpos[] = {1.0, 1.0, 7.0, 1.0};
  glLightfv(GL_LIGHT0, GL_POSITION, lightpos);
  
  GLfloat ambientLight[] = { 0.5f, 0.5f, 0.5f, 1.0f };
  GLfloat diffuseLight[] = { 0.8f, 0.8f, 0.8, 1.0f };
  GLfloat specularLight[] = { 0.5f, 0.5f, 0.5f, 1.0f };
  GLfloat position[] = { 1250.0f, 1250.0f, 2.0f, 1.0f };
  GLfloat position2[] = { -1250.0, 1250.0f, 2.0f, 1.0f};
  GLfloat position3[] = { 2.0f, 1250.0f, 1250.0f, 1.0f};
  
  
  glLightfv(GL_LIGHT0, GL_AMBIENT, ambientLight);
  glLightfv(GL_LIGHT0, GL_DIFFUSE, diffuseLight);
  glLightfv(GL_LIGHT0, GL_SPECULAR, specularLight);
  glLightfv(GL_LIGHT0, GL_POSITION, position);
  glLightfv(GL_LIGHT1, GL_POSITION, position2);
  glLightfv(GL_LIGHT1, GL_AMBIENT, ambientLight);
  glLightfv(GL_LIGHT1, GL_DIFFUSE, diffuseLight);
  glLightfv(GL_LIGHT1, GL_SPECULAR, specularLight);
  //glLightfv(GL_LIGHT2, GL_POSITION, position3);
  //glLightfv(GL_LIGHT2, GL_AMBIENT, ambientLight);
  //glLightfv(GL_LIGHT2, GL_DIFFUSE, diffuseLight);
  //glLightfv(GL_LIGHT2, GL_SPECULAR, specularLight);
  </code></pre>