title: Read pixel colours with OpenGL?
body: <p>I am trying to do collisions by reading the pixel colour of the pixel beside object, but I am confused about how to accomplish this. </p>
  
  <p>I read about <code>glreadpixels</code>, but I don't really understand the parameters, especially the last one, which is supposed to be of type <code>ByteBuffer</code>. Can anyone explain to me how can I accomplish this, or maybe a better way to do simple collision detection?</p>