title: how to get inverse of modelview matrix?
body: <p>I transformed a vector by multiplying it with the Model View matrix.  </p>
  
  <pre><code>glGetDoublev( GL_MODELVIEW_MATRIX, cam );
  newX=cam[0]*tx+cam[1]*ty+cam[2]*tz+cam[3];
  newY=cam[4]*tx+cam[5]*ty+cam[6]*tz+cam[7];
  newZ=cam[8]*tx+cam[9]*ty+cam[10]*tz+cam[11];
  </code></pre>
  
  <p>How to do I get the inverse of model view matrix for the reverse transformation? </p>