title: Problem enabling OpenGL ES depth test on iPhone. What steps are necessary?
body: <p>I remember running into this problem when I started using OpenGL in OS X. Eventually I solved it, but I think that was just by using glut and c++ instead of Objective-C...</p>
  
  <p>The lines of code I have in <code>init</code> for the <code>ES1Renderer</code> are as follows:</p>
  
  <pre><code>glEnable(GL_DEPTH_TEST);
  glDepthFunc(GL_LEQUAL);
  </code></pre>
  
  <p>Then in the <code>render</code> method, I have this:</p>
  
  <pre><code>glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
  </code></pre>
  
  <p>I assume I'm missing something specific to either the iPhone or ES. What other steps are required to enable the depth test?</p>
  
  <p>Thanks</p>