1GLDEPTHRANGE(3G)                                              GLDEPTHRANGE(3G)
2
3
4

NAME

6       glDepthRange  -  specify mapping of depth values from normalized device
7       coordinates to window coordinates
8
9

C SPECIFICATION

11       void glDepthRange( GLclampd near_val,
12                          GLclampd far_val )
13
14

PARAMETERS

16       near_val  Specifies the mapping of the near clipping  plane  to  window
17                 coordinates.  The initial value is 0.
18
19       far_val   Specifies  the  mapping  of  the far clipping plane to window
20                 coordinates.  The initial value is 1.
21

DESCRIPTION

23       After clipping and division by w, depth coordinates range from -1 to 1,
24       corresponding to the near and far clipping planes.  glDepthRange speci‐
25       fies a linear mapping of the normalized depth coordinates in this range
26       to  window  depth  coordinates.   Regardless of the actual depth buffer
27       implementation, window coordinate depth values are  treated  as  though
28       they  range from 0 through 1 (like color components).  Thus, the values
29       accepted by glDepthRange are both clamped to this range before they are
30       accepted.
31
32       The  setting  of (0,1) maps the near plane to 0 and the far plane to 1.
33       With this mapping, the depth buffer range is fully utilized.
34

NOTES

36       It is not necessary that near_val be less than far_val.   Reverse  map‐
37       pings such as near_val=1, and far_val=0 are acceptable.
38

ERRORS

40       GL_INVALID_OPERATION  is  generated if glDepthRange is executed between
41       the execution of glBegin and the corresponding execution of glEnd.
42

ASSOCIATED GETS

44       glGet with argument GL_DEPTH_RANGE
45

SEE ALSO

47       glDepthFunc(3G), glPolygonOffset(3G), glViewport(3G)
48
49
50
51                                                              GLDEPTHRANGE(3G)
Impressum