glOrtho(3) glOrtho(3)

## NAME

glOrtho- multiply the current matrix with an orthographic matrix

## C SPECIFICATION

voidglOrtho( GLdoubleleft, GLdoubleright, GLdoublebottom, GLdoubletop, GLdoublezNear, GLdoublezFar)

## PARAMETERS

left,rightSpecify the coordinates for the left and right vertical clipping planes.bottom,topSpecify the coordinates for the bottom and top horizontal clipping planes.zNear,zFarSpecify the distances to the nearer and farther depth clip- ping planes. These values are negative if the plane is to be behind the viewer.

## DESCRIPTION

glOrthodescribes a transformation that produces a parallel projection. The current matrix (seeglMatrixMode) is multiplied by this matrix and the result replaces the current matrix, as ifglMultMatrixwere called with the following matrix as its argument: 2 ------------ 0 0 tx right - left 2 0 ------------ 0 ty top - bottom -2 0 0 ------------ tz zFar-zNear 0 0 0 1 where tx = - (right + left) / (right - left) ty = - (top + bottom) / (top - bottom) tz = - (zFar + zNear) / (zFar - zNear) Typically, the matrix mode isGL_PROJECTION, and (left,bottom, -zNear) and (right,top, -zNear) specify the points on the near clip- ping plane that are mapped to the lower left and upper right corners of the window, respectively, assuming that the eye is located at (0, 0, 0). -zFarspecifies the location of the far clipping plane. BothzNearandzFarcan be either positive or negative. UseglPushMatrixandglPopMatrixto save and restore the current matrix stack.

## ERRORS

GL_INVALID_OPERATIONis generated ifglOrthois executed between the execution ofglBeginand the corresponding execution ofglEnd.

## ASSOCIATED GETS

glGetwith argumentGL_MATRIX_MODEglGetwith argumentGL_COLOR_MATRIXglGetwith argumentGL_MODELVIEW_MATRIXglGetwith argumentGL_PROJECTION_MATRIXglGetwith argumentGL_TEXTURE_MATRIX

## SEE ALSO

glFrustum(3),glMatrixMode(3),glMultMatrix(3),glPushMatrix(3),glViewport(3)glOrtho(3)

Mac OS X 10.6 - Generated Thu Sep 17 20:20:26 CDT 2009