PDA

View Full Version : orthogonal camera view



ThunderSoul
06-08-2005, 01:58 PM
how do u assign a camera for an orthogonal view and set it 2 units away from the origin?
thank you...

powerpad
06-08-2005, 02:26 PM
glOrtho(set up your orthographic projection here)

glTranslatef(pass your 2 units here)

Ehsan Kamrani
06-08-2005, 03:55 PM
Originally posted by ThunderSoul:
how do u assign a camera for an orthogonal view and set it 2 units away from the origin?
thank you...Try to use from two different matrices to do this. Apply the ortho viewing to the projection matrix and apply the translation to the modelview matrix.
Another way to translate the camera-Coordinate system essentially- to a specified place is to use from the gluLookAt() function. This function consist of some translatios and rotations to transform the current coordinate system.
-Ehsan-