82 lines
2.7 KiB
Plaintext
82 lines
2.7 KiB
Plaintext
|
'\" e
|
||
|
'\"! eqn | mmdoc
|
||
|
'\"macro stdmacro
|
||
|
.ds Vn Version 1.2
|
||
|
.ds Dt 24 September 1999
|
||
|
.ds Re Release 1.2.1
|
||
|
.ds Dp Jan 14 18:30
|
||
|
.ds Dm 01 clipplane
|
||
|
.ds Xs 34226 5 clipplane.gl
|
||
|
.TH GLCLIPPLANE 3G
|
||
|
.SH NAME
|
||
|
.B "glClipPlane
|
||
|
\- specify a plane against which all geometry is clipped
|
||
|
|
||
|
.SH C SPECIFICATION
|
||
|
void \f3glClipPlane\fP(
|
||
|
GLenum \fIplane\fP,
|
||
|
.nf
|
||
|
.ta \w'\f3void \fPglClipPlane( 'u
|
||
|
const GLdouble \fI*equation\fP )
|
||
|
.fi
|
||
|
|
||
|
.EQ
|
||
|
delim $$
|
||
|
.EN
|
||
|
.SH PARAMETERS
|
||
|
.TP \w'\fIequation\fP\ \ 'u
|
||
|
\f2plane\fP
|
||
|
Specifies which clipping plane is being positioned.
|
||
|
Symbolic names of the form \%\f3GL_CLIP_PLANE\fP\f2i\fP,
|
||
|
where \f2i\fP is an integer between 0 and \%\f3GL_MAX_CLIP_PLANES\fP$^-^1$,
|
||
|
are accepted.
|
||
|
.TP
|
||
|
\f2equation\fP
|
||
|
Specifies the address of an array of four double-precision floating-point values.
|
||
|
These values are interpreted as a plane equation.
|
||
|
.SH DESCRIPTION
|
||
|
Geometry is always clipped against the boundaries of a six-plane frustum
|
||
|
in \f2x\fP, \f2y\fP, and \f2z\fP.
|
||
|
\%\f3glClipPlane\fP allows the specification of additional planes,
|
||
|
not necessarily perpendicular to the \f2x\fP, \f2y\fP, or \f2z\fP axis,
|
||
|
against which all geometry is clipped.
|
||
|
To determine the maximum number of additional clipping planes, call
|
||
|
\%\f3glGetIntegerv\fP with argument \%\f3GL_MAX_CLIP_PLANES\fP. All
|
||
|
implementations support at least six such clipping planes.
|
||
|
Because the resulting clipping region is the intersection
|
||
|
of the defined half-spaces,
|
||
|
it is always convex.
|
||
|
.P
|
||
|
\%\f3glClipPlane\fP specifies a half-space using a four-component plane equation.
|
||
|
When \%\f3glClipPlane\fP is called,
|
||
|
\f2equation\fP is transformed by the inverse of the modelview matrix
|
||
|
and stored in the resulting eye coordinates.
|
||
|
Subsequent changes to the modelview matrix have no effect on the
|
||
|
stored plane-equation components.
|
||
|
If the dot product of the eye coordinates of a vertex with the
|
||
|
stored plane equation components is positive or zero,
|
||
|
the vertex is \f2in\f1 with respect to that clipping plane.
|
||
|
Otherwise, it is \f2out\fP.
|
||
|
.P
|
||
|
To enable and disable clipping planes, call
|
||
|
\%\f3glEnable\fP and \%\f3glDisable\fP with the argument
|
||
|
\%\f3GL_CLIP_PLANE\fP\f2i\fP,
|
||
|
where \f2i\fP is the plane number.
|
||
|
.P
|
||
|
All clipping planes are initially defined as (0, 0, 0, 0) in eye coordinates
|
||
|
and are disabled.
|
||
|
.SH NOTES
|
||
|
It is always the case that \%\f3GL_CLIP_PLANE\fP$i$ = \%\f3GL_CLIP_PLANE0\fP$~+~i$.
|
||
|
.SH ERRORS
|
||
|
\%\f3GL_INVALID_ENUM\fP is generated if \f2plane\fP is not an accepted value.
|
||
|
.P
|
||
|
\%\f3GL_INVALID_OPERATION\fP is generated if \%\f3glClipPlane\fP
|
||
|
is executed between the execution of \%\f3glBegin\fP
|
||
|
and the corresponding execution of \%\f3glEnd\fP.
|
||
|
.SH ASSOCIATED GETS
|
||
|
\%\f3glGetClipPlane\fP
|
||
|
.br
|
||
|
\%\f3glIsEnabled\fP with argument \%\f3GL_CLIP_PLANE\fP\f2i\fP
|
||
|
.SH SEE ALSO
|
||
|
\%\f3glEnable(3G)\fP
|