'\" t .\" Title: glDepthRange .\" Author: [FIXME: author] [see http://docbook.sf.net/el/author] .\" Generator: DocBook XSL Stylesheets v1.78.1 .\" Date: 05/21/2015 .\" Manual: [FIXME: manual] .\" Source: [FIXME: source] .\" Language: English .\" .TH "GLDEPTHRANGE" "3G" "05/21/2015" "[FIXME: source]" "[FIXME: manual]" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" glDepthRange \- specify mapping of depth values from normalized device coordinates to window coordinates .SH "C SPECIFICATION" .HP \w'void\ glDepthRange('u .BI "void glDepthRange(GLdouble\ " "nearVal" ", GLdouble\ " "farVal" ");" .HP \w'void\ glDepthRangef('u .BI "void glDepthRangef(GLfloat\ " "nearVal" ", GLfloat\ " "farVal" ");" .SH "PARAMETERS" .PP \fInearVal\fR .RS 4 Specifies the mapping of the near clipping plane to window coordinates\&. The initial value is 0\&. .RE .PP \fIfarVal\fR .RS 4 Specifies the mapping of the far clipping plane to window coordinates\&. The initial value is 1\&. .RE .SH "DESCRIPTION" .PP After clipping and division by \fIw\fR, depth coordinates range from \-1 to 1, corresponding to the near and far clipping planes\&. \fBglDepthRange\fR specifies a linear mapping of the normalized depth coordinates in this range to window depth coordinates\&. Regardless of the actual depth buffer implementation, window coordinate depth values are treated as though they range from 0 through 1 (like color components)\&. Thus, the values accepted by \fBglDepthRange\fR are both clamped to this range before they are accepted\&. .PP The setting of (0,1) maps the near plane to 0 and the far plane to 1\&. With this mapping, the depth buffer range is fully utilized\&. .SH "NOTES" .PP It is not necessary that \fInearVal\fR be less than \fIfarVal\fR\&. Reverse mappings such as nearVal = 1, and farVal = 0 are acceptable\&. .PP The type of the \fInearVal\fR and \fIfarVal\fR parameters was changed from GLclampf to GLfloat for \fBglDepthRangef\fR and from GLclampd to GLdouble for \fBglDepthRange\fR\&. This change is transparent to user code and is described in detail on the \fBremovedTypes\fR() page\&. .SH "ASSOCIATED GETS" .PP \fBglGet\fR() with argument \fBGL_DEPTH_RANGE\fR .SH "VERSION SUPPORT" .TS allbox tab(:); lB cB s s s s s s s s s s s lB cB cB cB cB cB cB cB cB cB cB cB cB. T{ T}:T{ \fBOpenGL Version\fR T} T{ \fBFunction / Feature Name\fR T}:T{ \fB2\&.0\fR T}:T{ \fB2\&.1\fR T}:T{ \fB3\&.0\fR T}:T{ \fB3\&.1\fR T}:T{ \fB3\&.2\fR T}:T{ \fB3\&.3\fR T}:T{ \fB4\&.0\fR T}:T{ \fB4\&.1\fR T}:T{ \fB4\&.2\fR T}:T{ \fB4\&.3\fR T}:T{ \fB4\&.4\fR T}:T{ \fB4\&.5\fR T} .T& l c c c c c c c c c c c c l c c c c c c c c c c c c. T{ \fBglDepthRange\fR T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T} T{ \fBglDepthRangef\fR T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ \- T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T}:T{ ✔ T} .TE .sp .SH "SEE ALSO" .PP \fBglDepthFunc\fR(), \fBglPolygonOffset\fR(), \fBglViewport\fR(), \fBremovedTypes\fR() .SH "COPYRIGHT" .PP Copyright \(co 1991\-2006 Silicon Graphics, Inc\&. Copyright \(co 2010\-2014 Khronos Group\&. This document is licensed under the SGI Free Software B License\&. For details, see \m[blue]\fBhttp://oss\&.sgi\&.com/projects/FreeB/\fR\m[]\&. .SH "COPYRIGHT" .br Copyright \(co 1991-2006 Silicon Graphics, Inc. .br Copyright \(co 2010-2014 Khronos Group .br