title: webgl drawing order, stencil buffer
body: <p>I'm reading through learningwebgl.com and what confuses me is that it draws the first buffer I bound as last element?</p>
  
  <p><a href="http://jsfiddle.net/Cx8gG/1/" rel="nofollow">http://jsfiddle.net/Cx8gG/1/</a></p>
  
  <pre><code>red triangle
  green square
  blue square
  </code></pre>
  
  <p>I expected to see only the blue square because everything else gets overdrawn, the output seems to be in reverse order?</p>
  
  <p>I've also read about stencil buffers, so what I tried to do is create a mask (red) and then there should be a green triangle on the blue square.</p>
  
  <p>the mask works ( <a href="http://jsfiddle.net/D3QNg/3/" rel="nofollow">http://jsfiddle.net/D3QNg/3/</a> ) but I don't know if it's right or if I'm just lucky.</p>
  
  <p>Would appreciate some help.</p>