title: Multiple UBOs without specifying binding point index explicitly
body: <p>I am looking into OpenGL Uniform Buffer Objects and Shader Storage Buffers. I think the question applies to both of them, but let's just focus on UBOs.</p>
  
  <p>Tutorials seem to be saying that "block index" and "binding point index" are different things, and if I have more than one UBO in a shader, I need to specify the binding index</p>
  
  <pre class="lang-c prettyprint-override"><code>layout(binding = 0) uniform first_buffer  {...};
  layout(binding = 1) uniform second_buffer {...};
  </code></pre>
  
  <p>I get the impression that the block index is determined by the linker and can be read from <code>glGetUniformBlockIndex</code>, but the binding point index has to be hard-coded with arbitrary distinct <code>binding=N</code> in the layout, and a corresponding <code>glBindBufferBase(GL_UNIFORM_BUFFER, N, ubo_handle)</code>, which strikes me as fragile and a nuisance.</p>
  
  <p>What is the difference between a block index and a binding point?</p>
  
  <p>Can I omit the <code>binding=N</code> in the layout? What happens then with <code>glBindBufferBase</code>?</p>
  
  <p>Is this all the same for SSBOs?</p>