1GLUTESSNORMAL(3G) GLUTESSNORMAL(3G)
2
3
4
6 gluTessNormal - specify a normal for a polygon
7
8
10 void gluTessNormal( GLUtesselator* tess,
11 GLdouble valueX,
12 GLdouble valueY,
13 GLdouble valueZ )
14
15
17 tess Specifies the tessellation object (created with gluNewTess).
18
19 valueX Specifies the first component of the normal.
20
21 valueY Specifies the second component of the normal.
22
23 valueZ Specifies the third component of the normal.
24
26 gluTessNormal describes a normal for a polygon that the program is
27 defining. All input data will be projected onto a plane perpendicular
28 to one of the three coordinate axes before tessellation and all output
29 triangles will be oriented CCW with respect to the normal (CW orienta‐
30 tion can be obtained by reversing the sign of the supplied normal). For
31 example, if you know that all polygons lie in the x-y plane, call
32 gluTessNormal(tess, 0.0, 0.0, 1.0) before rendering any polygons.
33
34 If the supplied normal is (0.0, 0.0, 0.0) (the initial value), the nor‐
35 mal is determined as follows. The direction of the normal, up to its
36 sign, is found by fitting a plane to the vertices, without regard to
37 how the vertices are connected. It is expected that the input data lies
38 approximately in the plane; otherwise, projection perpendicular to one
39 of the three coordinate axes may substantially change the geometry. The
40 sign of the normal is chosen so that the sum of the signed areas of all
41 input contours is nonnegative (where a CCW contour has positive area).
42
43 The supplied normal persists until it is changed by another call to
44 gluTessNormal.
45
47 gluTessBeginPolygon(3G), gluTessEndPolygon(3G)
48
49
50
51
52
53
54 GLUTESSNORMAL(3G)