title: How can I have a uniform buffer array of chars or shorts?
body: <p>Apparently OpenGL doesn't have types that are 8 bit or 16 bit. I need to send a uniform array with each element of the array consisting of:</p>
  <pre><code>unsigned short (16 bit) xPosition;
  unsigned short (16 bit) yPosition;
  unsigned short (16 bit) radius;
  </code></pre>
  <p>Each triangle references these values, so I can divide by gl_VertexID to get the current triangle that is being drawn. The problem is that these values are 3 shorts (48bits, 3 bytes) each. If I'm drawing vertex number 8 for example I can do 8 / 3 = 2, and I know I'm drawing triangle 2 (the third triangle), but then how do I index into the uniform buffer to get the xPosition, yPosition and radius? Is there no simple way to just have a uniform buffer array or chars or shorts in glsl?</p>