1GLORTHO(3G)                      OpenGL Manual                     GLORTHO(3G)
2
3
4

NAME

6       glOrtho - multiply the current matrix with an orthographic matrix
7

C SPECIFICATION

9       void glOrtho(GLdouble left, GLdouble right, GLdouble bottom,
10                    GLdouble top, GLdouble nearVal, GLdouble farVal);
11

PARAMETERS

13       left, right
14           Specify the coordinates for the left and right vertical clipping
15           planes.
16
17       bottom, top
18           Specify the coordinates for the bottom and top horizontal clipping
19           planes.
20
21       nearVal, farVal
22           Specify the distances to the nearer and farther depth clipping
23           planes. These values are negative if the plane is to be behind the
24           viewer.
25

DESCRIPTION

27       glOrtho describes a transformation that produces a parallel projection.
28       The current matrix (see glMatrixMode()) is multiplied by this matrix
29       and the result replaces the current matrix, as if glMultMatrix() were
30       called with the following matrix as its argument:
31
32       2 right - left 0 0 t x 0 2 top - bottom 0 t y 0 0 -2 farVal - nearVal t
33       z 0 0 0 1
34
35       where t x = - right + left right - leftt y = - top + bottom top -
36       bottomt z = - farVal + nearVal farVal - nearVal
37
38       Typically, the matrix mode is GL_PROJECTION, and left bottom - nearVal
39       and right top - nearVal specify the points on the near clipping plane
40       that are mapped to the lower left and upper right corners of the
41       window, respectively, assuming that the eye is located at (0, 0, 0).  -
42       farVal specifies the location of the far clipping plane. Both nearVal
43       and farVal can be either positive or negative.
44
45       Use glPushMatrix() and glPopMatrix() to save and restore the current
46       matrix stack.
47

ERRORS

49       GL_INVALID_VALUE is generated if left = right, or bottom = top, or near
50       = far.
51
52       GL_INVALID_OPERATION is generated if glOrtho is executed between the
53       execution of glBegin() and the corresponding execution of glEnd().
54

ASSOCIATED GETS

56       glGet() with argument GL_MATRIX_MODE
57
58       glGet() with argument GL_COLOR_MATRIX
59
60       glGet() with argument GL_MODELVIEW_MATRIX
61
62       glGet() with argument GL_PROJECTION_MATRIX
63
64       glGet() with argument GL_TEXTURE_MATRIX
65

SEE ALSO

67       glFrustum(), glMatrixMode(), glMultMatrix(), glPushMatrix(),
68       glViewport()
69
71       Copyright © 1991-2006 Silicon Graphics, Inc. This document is licensed
72       under the SGI Free Software B License. For details, see
73       http://oss.sgi.com/projects/FreeB/.
74

AUTHORS

76       opengl.org
77
78
79
80opengl.org                        06/10/2014                       GLORTHO(3G)
Impressum