PDA

View Full Version : gluLookAt and glOrtho



03-15-2004, 09:03 PM
Can I use gluLookAt if I'm using orthographic projection?

Also, is there anything gluLookAt can accomplish that can't be done with glRotate?

Thanks

SmutMonkey
03-15-2004, 10:34 PM
gluLookAt calculates a view matrix, which essentially describes a transformation from world space to camera space. Nothing at all to do with the projection matrix, so you can use it with whichever projection method you like.

You can do the same as gluLookAt using glTranslate and glMultMatrix (well, you could use glRotate but you need to do more overall work). Check out the blue book (or an online reference) for how to construct the matrix.