378a1dbb32cc9cd18eed400ba6a1d0a750ac4cfc
[clinton/guile-figl.git] / upstream-man-pages / man2 / xhtml / gluTessProperty.xml
1 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "xhtml1-transitional.dtd">
2 <!-- saved from url=(0013)about:internet -->
3 <?xml-stylesheet type="text/xsl" href="mathml.xsl"?><html xmlns="http://www.w3.org/1999/xhtml" xmlns:pref="http://www.w3.org/2002/Math/preference" pref:renderer="mathplayer-dl"><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /><title>gluTessProperty</title><meta name="generator" content="DocBook XSL Stylesheets V1.73.2" /></head><body><div class="refentry" lang="en" xml:lang="en"><a id="gluTessProperty"></a><div class="titlepage"></div><div class="refnamediv"><h2>Name</h2><p>gluTessProperty — set a tessellation object property</p></div><div class="refsynopsisdiv"><h2>C Specification</h2><div class="funcsynopsis"><table border="0" summary="Function synopsis" cellspacing="0" cellpadding="0"><tr><td><code class="funcdef">void <b class="fsfunc">gluTessProperty</b>(</code></td><td>GLUtesselator*  </td><td><var class="pdparam">tess</var>, </td></tr><tr><td> </td><td>GLenum  </td><td><var class="pdparam">which</var>, </td></tr><tr><td> </td><td>GLdouble  </td><td><var class="pdparam">data</var><code>)</code>;</td></tr></table></div></div><div class="refsect1" lang="en" xml:lang="en"><a id="parameters"></a><h2>Parameters</h2><div class="variablelist"><dl><dt><span class="term"><em class="parameter"><code>tess</code></em></span></dt><dd><p>
4 Specifies the tessellation object (created with <a class="citerefentry" href="gluNewTess.xml"><span class="citerefentry"><span class="refentrytitle">gluNewTess</span></span></a>).
5 </p></dd><dt><span class="term"><em class="parameter"><code>which</code></em></span></dt><dd><p>
6 Specifies the property to be set. Valid values are
7 <code class="constant">GLU_TESS_WINDING_RULE</code>,
8 <code class="constant">GLU_TESS_BOUNDARY_ONLY</code>, and
9 <code class="constant">GLU_TESS_TOLERANCE</code>.
10 </p></dd><dt><span class="term"><em class="parameter"><code>data</code></em></span></dt><dd><p>
11 Specifies the value of the indicated property.
12 </p></dd></dl></div></div><div class="refsect1" lang="en" xml:lang="en"><a id="description"></a><h2>Description</h2><p>
13 <code class="function">gluTessProperty</code> is used to control properties stored in a tessellation object. These
14 properties affect the way that the polygons are interpreted and rendered.
15 The legal values for <em class="parameter"><code>which</code></em> are as follows:
16 </p><div class="variablelist"><dl><dt><span class="term"><code class="constant">GLU_TESS_WINDING_RULE</code> </span></dt><dd><p>
17 Determines which parts of the polygon are on the ``interior''.
18 <em class="parameter"><code>data</code></em> may be set to one of <code class="constant">GLU_TESS_WINDING_ODD</code>,
19 <code class="constant">GLU_TESS_WINDING_NONZERO</code>, <code class="constant">GLU_TESS_WINDING_POSITIVE</code>,
20 <code class="constant">GLU_TESS_WINDING_NEGATIVE</code>, or <code class="constant">GLU_TESS_WINDING_ABS_GEQ_TWO</code>.
21 </p><p>
22 To understand how the winding rule works, consider that the input
23 contours partition the plane into regions. The winding rule determines which
24 of these regions are inside the polygon.
25 </p><p>
26 For a single contour C, the winding number of a point x is simply the signed
27 number of revolutions we make around x as we travel once around C
28 (where CCW is positive). When there are several contours, the individual
29 winding numbers are summed. This procedure associates a signed integer
30 value with each point x in the plane. Note that the winding number is the
31 same for all points in a single region.
32 </p><p>
33 The winding rule classifies a region as ``inside'' if its winding number
34 belongs to the chosen category (odd, nonzero, positive, negative, or
35 absolute value of at least two). The previous GLU tessellator (prior to
36 GLU 1.2) used the ``odd'' rule. The ``nonzero'' rule is another common way to
37 define the interior. The other three rules are useful for polygon CSG
38 operations.
39 </p></dd><dt><span class="term"><code class="constant">GLU_TESS_BOUNDARY_ONLY</code> </span></dt><dd><p>
40 Is a boolean value (``value'' should be set
41 to GL_TRUE or GL_FALSE). When set to GL_TRUE, a set of closed contours
42 separating the polygon interior and exterior are returned instead of a
43 tessellation. Exterior contours are oriented CCW with respect to the
44 normal; interior contours are oriented CW. The <code class="constant">GLU_TESS_BEGIN</code>
45 and <code class="constant">GLU_TESS_BEGIN_DATA</code> callbacks use the type GL_LINE_LOOP for
46 each contour.
47 </p></dd><dt><span class="term"><code class="constant">GLU_TESS_TOLERANCE</code></span></dt><dd><p>
48 Specifies a tolerance for merging features to reduce the size of the output.
49 For example, two vertices that are very close to each other might be
50 replaced by a single vertex. The tolerance is multiplied by the largest
51 coordinate magnitude of any input vertex; this specifies the maximum
52 distance that any feature can move as the result of a single merge
53 operation. If a single feature takes part in several merge operations, the
54 total distance moved could be larger.
55 </p><p>
56 Feature merging is completely optional; the tolerance is only a hint.
57 The implementation is free to merge in some cases and not in others, or to
58 never merge features at all. The initial tolerance is 0.
59 </p><p>
60 The current implementation merges vertices only if they are exactly
61 coincident, regardless of the current tolerance. A vertex is spliced into
62 an edge only if the implementation is unable to distinguish which side of
63 the edge the vertex lies on. Two edges are merged only when both endpoints
64 are identical.
65 </p></dd></dl></div></div><div class="refsect1" lang="en" xml:lang="en"><a id="seealso"></a><h2>See Also</h2><p>
66 <a class="citerefentry" href="gluGetTessProperty.xml"><span class="citerefentry"><span class="refentrytitle">gluGetTessProperty</span></span></a>,
67 <a class="citerefentry" href="gluNewTess.xml"><span class="citerefentry"><span class="refentrytitle">gluNewTess</span></span></a>
68 </p></div><div class="refsect1" lang="en" xml:lang="en"><a id="Copyright"></a><h2>Copyright</h2><p>
69 Copyright <span class="trademark"></span>© 1991-2006
70 Silicon Graphics, Inc. This document is licensed under the SGI
71 Free Software B License. For details, see
72 <a class="ulink" href="http://oss.sgi.com/projects/FreeB/" target="_top">http://oss.sgi.com/projects/FreeB/</a>.
73 </p></div></div></body></html>