summaryrefslogtreecommitdiff
path: root/doc/gl-docs/GLU/beginsurface.3gl
blob: 4a7ff6b1e869139989e1b14232773e86c2906339 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
'\" e
'\"! eqn | mmdoc
'\"macro stdmacro
.ds Vn Version 1.2
.ds Dt 6 March 1997
.ds Re Release 1.2.0
.ds Dp May 02 11:53
.ds Dm 37 beginsurf
.ds Xs 47264 4 beginsurface.gl
.TH GLUBEGINSURFACE 3G
.SH NAME
.B "gluBeginSurface, gluEndSurface
\- delimit a NURBS surface definition

.SH C SPECIFICATION
void \f3gluBeginSurface\fP(
GLUnurbs* \fInurb\fP )
.nf
.fi

void \f3gluEndSurface\fP(
GLUnurbs* \fInurb\fP )
.nf
.fi

.EQ
delim $$
.EN
.SH PARAMETERS
.TP \w'\f2nurb\fP\ \ 'u 
\f2nurb\fP
Specifies the NURBS object (created with \%\f3gluNewNurbsRenderer\fP).
.SH DESCRIPTION
Use \%\f3gluBeginSurface\fP to mark the beginning of a NURBS 
surface definition. After 
calling \%\f3gluBeginSurface\fP, make one or more calls to
\%\f3gluNurbsSurface\fP to define the attributes of the surface.
Exactly one of these calls to \%\f3gluNurbsSurface\fP must have a
surface type of \%\f3GL_MAP2_VERTEX_3\fP or \%\f3GL_MAP2_VERTEX_4\fP.
To mark the end of the NURBS surface definition, call
\%\f3gluEndSurface\fP.
.P
Trimming of NURBS surfaces is supported with \%\f3gluBeginTrim\fP, 
\%\f3gluPwlCurve\fP, \%\f3gluNurbsCurve\fP, and \%\f3gluEndTrim\fP. See the
\%\f3gluBeginTrim\fP reference page for details.
.P
GL evaluators are used to render the NURBS surface as a set of polygons.
Evaluator state is preserved during rendering
with \f3glPushAttrib\fP(\%\f3GL_EVAL_BIT\fP) and 
\f3glPopAttrib\fP().  
See the \f3glPushAttrib\fP reference page for details on exactly what state
these calls preserve.
.SH EXAMPLE
The following commands render a textured NURBS surface with normals;
the texture coordinates and normals are also described as NURBS surfaces:
.sp
.Ex
gluBeginSurface(nobj);
   gluNurbsSurface(nobj, ..., GL_MAP2_TEXTURE_COORD_2);
   gluNurbsSurface(nobj, ..., GL_MAP2_NORMAL);
   gluNurbsSurface(nobj, ..., GL_MAP2_VERTEX_4);
gluEndSurface(nobj);
.Ee
.sp
.SH SEE ALSO
\%\f3gluBeginCurve(3G)\fP, \%\f3gluBeginTrim(3G)\fP, \%\f3gluNewNurbsRenderer(3G)\fP, 
\%\f3gluNurbsCurve(3G)\fP, \%\f3gluNurbsSurface(3G)\fP, \%\f3gluPwlCurve(3G)\fP