This file is indexed.

/usr/share/doc/gle-doc/html/tube.html is in gle-doc 3.1.0-7ubuntu2.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

  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
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"> 
<html>
<! 

    GLE extrusion, sweep and tubing library
>
<head>
<title>Subroutine Documentation</title>
<meta name="description" content="The GLE Tubing and Extrusion Library
    is a graphics programming interface (API) for drawing
    tubing, extrusions and sweeps using the OpenGL API.">
<meta name="keywords" content="GLE, tubing, extrusion, graphics, OpenGL,
    lathe, sweep, torus, polycylinder, polycone, contour, parallel
    translation, helix, texture mapping">
</head>

<body>
<h1>Subroutine Documentation</h1>

<h2>Some Types</h2>

<pre>
typedef double gleDouble;
typedef gleDouble gleAffine[2][3];
</pre>


<h2>Subroutine Descriptions</h2>

<dl>

<img src="angle.gif">
<dt>
<pre><b> void glePolyCylinder (int npoints,		/* num points in polyline */
                   gleDouble point_array[][3],	/* polyline vertces */
                   float color_array[][3],	/* colors at polyline verts */
                   gleDouble radius);		/* radius of polycylinder */
</b></pre>
<pre><b> void glePolyCylinder_c4f (int npoints,		/* num points in polyline */
                   gleDouble point_array[][3],	/* polyline vertces */
                   float color_array[][4],	/* colors at polyline verts */
                   gleDouble radius);		/* radius of polycylinder */
</b></pre>
<dd>
Draw polycylinder, specified as a polyline.

<p>
Note that neither the very first segment, nor the very last segment are
drawn.  The first and last segments serve only to define the angle of
the join at the very ends of the polyline.  Thus, to draw one segment,
three must be specified. To draw two segments, four must be specified,
etc.

<p>
The color array may be NULL. If NULL, the current color is used.  If not
NULL, the glColor3f() routine is used to set the color; therefore,
specifying the glColorMaterial() subroutine before this primitive can be used
to set diffuse, specular, ambient, etc. colors.
The glePolyCylinder_c4f() routine calls glColor4f() instead, thus allowing
alpha-blending (transparency) to be performed.
<p>
By default, the cross-section of the cylinder is drawn as a 20-sided
polygon.  This number can be changed using the gleSetNumSides() routine.
<p>

<img src="cone.gif">
<dt>
<pre><b> void glePolyCone (int npoints,	 /* numpoints in poly-line */
                   gleDouble point_array[][3],	/* polyline vertices */
                   float color_array[][3],	/* colors at polyline verts */
                   gleDouble radius_array[]); /* cone radii at polyline verts */
</b></pre>
<pre><b> void glePolyCone_c4f (int npoints,	 /* numpoints in poly-line */
                   gleDouble point_array[][3],	/* polyline vertices */
                   float color_array[][4],	/* colors at polyline verts */
                   gleDouble radius_array[]); /* cone radii at polyline verts */
</b></pre>
<dd>
Draw polycone, specified as a polyline with radii.
<p>
Note that neither the very first segment, nor the very last segment are
drawn.  The first and last segments serve only to define the angle of
the join at the very ends of the polyline.  Thus, to draw one segment,
three must be specified. To draw two segments, four must be specified,
<i>etc.</i>

<p>
The color array may be NULL. If NULL, the current color is used.  If not
NULL, the glColor3f() routine is used to set the color; therefore,
specifying the glColorMaterial() subroutine before this primitive can be used
to set diffuse, specular, ambient, <i>etc.</i> colors.
The glePolyCone_c4f() routine calls glColor4f() instead, thus allowing
alpha-blending (transparency) to be performed.
<p>
By default, the cross-section of the cylinder is drawn as a 20-sided
polygon.  This number can be changed using the gleSetNumSides() routine.
<p>

<dt><pre><b> int gleGetNumSides(void);
 void gleSetNumSides(int slices);
</b></pre>
<dd>
Query and set the GLE cylinder and cone roundness. When GLE draws
a cylinder or a cone, it approximates the circular cross-section
with a polygon (of 20 sides by default).  These subroutines can
be used to change the default number of sides in this cross-section.
A smaller number of sides can typically be drawn much faster, at
the loss of some visual accuracy.  Increasing the number of sides to
more than 20 will typically have no noticeable visual effect.
<p>


<img src="texas.gif">
<dt>
<pre><b> void gleExtrusion (int ncp,         /* number of contour points */
                gleDouble contour[][2],     /* 2D contour */
                gleDouble cont_normal[][2], /* 2D contour normals */
                gleDouble up[3],            /* up vector for contour */
                int npoints,            /* numpoints in poly-line */
                gleDouble point_array[][3], /* polyline vertices */
                float color_array[][3]); /* colors at polyline verts */
</b></pre>
<pre><b> void gleExtrusion_c4f (int ncp,         /* number of contour points */
                gleDouble contour[][2],     /* 2D contour */
                gleDouble cont_normal[][2], /* 2D contour normals */
                gleDouble up[3],            /* up vector for contour */
                int npoints,            /* numpoints in poly-line */
                gleDouble point_array[][3], /* polyline vertices */
                float color_array[][4]); /* colors at polyline verts */
</b></pre>
<dd>Extrude arbitrary 2D contour along arbitrary 3D path.
The argument "contour" specifies the 2D contour to be extruded, while the
argument "point_array" specifies the path along which to extrude.  The
vector "up" defines the orientation of the contour y-axis in real 3D space.
<p>
Note that neither the very first segment, nor the very last segment are
drawn.  The first and last segments serve only to define the angle of
the join at the very ends of the polyline.  Thus, to draw one segment,
three must be specified. To draw two segments, four must be specified,
<i>etc.</i>


<p>
The normal array may be NULL.  If it is, normal vectors will NOT be
automatically generated, and the object will look terrible when lit.

<p>
The color array may be NULL. If NULL, the current color is used.  If not
NULL, the glColor3f() routine is used to set the color; therefore,
specifying the glColorMaterial() subroutine before this primitive can be used
to set diffuse, specular, ambient, <i>etc.</i> colors.
The gleExtrusion_c4f() routine calls glColor4f() instead, thus allowing
alpha-blending (transparency) to be performed.
<p>

<img src="twist1.gif">
<img src="twist2.gif">
<img src="twist3.gif">
<dt>
<pre><b> void gleTwistExtrusion (int ncp,         /* number of contour points */
                gleDouble contour[][2],    /* 2D contour */
                gleDouble cont_normal[][2], /* 2D contour normals */
                gleDouble up[3],           /* up vector for contour */
                int npoints,           /* numpoints in poly-line */
                gleDouble point_array[][3],        /* polyline vertices */
                float color_array[][3],        /* color at polyline verts */
                gleDouble twist_array[]);   /* contour twists (in degrees) */
</b></pre>
<pre><b> void gleTwistExtrusion_c4f (int ncp,         /* number of contour points */
                gleDouble contour[][2],    /* 2D contour */
                gleDouble cont_normal[][2], /* 2D contour normals */
                gleDouble up[3],           /* up vector for contour */
                int npoints,           /* numpoints in poly-line */
                gleDouble point_array[][3],        /* polyline vertices */
                float color_array[][4],        /* color at polyline verts */
                gleDouble twist_array[]);   /* contour twists (in degrees) */
</b></pre>
<dd>Extrude arbitrary 2D contour along arbitrary 3D path, specifying local
rotations (twists). As the contour is extruded, it will be twisted by the
amount specified in the array "twist_array".  The angles are measured in
degrees, and the rotation is about the origin of the contour coordinate
system.

<p>
The argument "contour" specifies the 2D contour to be extruded, while the
argument "point_array" specifies the path along which to extrude.  The
vector "up" defines the orientation of the contour y-axis in real 3D space.

<p>
Note that neither the very first segment, nor the very last segment are
drawn.  The first and last segments serve only to define the angle of
the join at the very ends of the polyline.  Thus, to draw one segment,
three must be specified. To draw two segments, four must be specified,
<i>etc.</i>

<p>
The normal array may be NULL.  If it is, normal vectors will NOT be
automatically generated, and the object will look terrible when lit.

<p>
The color array may be NULL. If NULL, the current color is used.  If not
NULL, the glColor3f() routine is used to set the color; therefore,
specifying the glColorMaterial() subroutine before this primitive can be used
to set diffuse, specular, ambient, <i>etc.</i> colors.
The gleTwistExtrusion_c4f() routine calls glColor4f() instead, thus allowing
alpha-blending (transparency) to be performed.
<p>


<dt>
<pre><b> void gleSuperExtrusion (int ncp,  /* number of contour points */
                gleDouble contour[][2],    /* 2D contour */
                gleDouble cont_normal[][2], /* 2D contour normals */
                gleDouble up[3],           /* up vector for contour */
                int npoints,           /* numpoints in poly-line */
                gleDouble point_array[][3],        /* polyline vertices */
                float color_array[][3],        /* color at polyline verts */
                gleDouble xform_array[][2][3]);   /* 2D contour xforms */
</b></pre>
<pre><b> void gleSuperExtrusion_c4f (int ncp,  /* number of contour points */
                gleDouble contour[][2],    /* 2D contour */
                gleDouble cont_normal[][2], /* 2D contour normals */
                gleDouble up[3],           /* up vector for contour */
                int npoints,           /* numpoints in poly-line */
                gleDouble point_array[][3],        /* polyline vertices */
                float color_array[][4],        /* color at polyline verts */
                gleDouble xform_array[][2][3]);   /* 2D contour xforms */
</b></pre>
<dd>Extrude arbitrary 2D contour along arbitrary 3D path, specifying local
affine transformations. As the contour is extruded, the affine will be
applied to the points in the contour.

<p>
The argument "contour" specifies the 2D contour to be extruded, while the
argument "point_array" specifies the path along which to extrude.  The
vector "up" defines the orientation of the contour y-axis in real 3D space.

<p>
Note that neither the very first segment, nor the very last segment are
drawn.  The first and last segments serve only to define the angle of
the join at the very ends of the polyline.  Thus, to draw one segment,
three must be specified. To draw two segments, four must be specified,
<i>etc.</i>

<p>
The normal array may be NULL.  If it is, normal vectors will NOT be
automatically generated, and the object will look terrible when lit.

<p>
The color array may be NULL. If NULL, the current color is used.  If not
NULL, the glColor3f() routine is used to set the color; therefore,
specifying the glColorMaterial() subroutine before this primitive can be used
to set diffuse, specular, ambient, <i>etc.</i> colors.
The gleSuperExtrusion_c4f() routine calls glColor4f() instead, thus allowing
alpha-blending (transparency) to be performed.
<p>

<img src="shear.gif">

<dt><pre><b> void gleSpiral (int ncp,        /* number of contour points */
             gleDouble contour[][2],    /* 2D contour */
             gleDouble cont_normal[][2], /* 2D contour normals */
             gleDouble up[3],           /* up vector for contour */
             gleDouble startRadius,	/* spiral starts in x-y plane */
             gleDouble drdTheta,        /* change in radius per revolution */
             gleDouble startZ,		/* starting z value */
             gleDouble dzdTheta,        /* change in Z per revolution */
             gleDouble startXform[2][3], /* starting contour affine xform */
             gleDouble dXformdTheta[2][3], /* tangent change xform per revoln */
             gleDouble startTheta,	/* start angle in x-y plane */
             gleDouble sweepTheta);	/* degrees to spiral around */
</b></pre>
<dd>
Sweep an arbitrary contour along a helical path.
<p>
The axis of the helix lies along the modeling coordinate z-axis.
<p>
An affine transform can be applied as the contour is swept.  For most
ordinary usage, the affines should be given as NULL.
<p>
The "startXform[][]" is an affine matrix 
applied to the contour to deform the contour. 
Thus, "startXform" of the form
<pre>
|  cos     sin    0   |
|  -sin    cos    0   |
</pre>
will rotate the contour (in the plane of the contour), while
<pre>
|  1    0    tx   |
|  0    1    ty   |
</pre>
will translate the contour, and
<pre>
|  sx    0    0   |
|  0    sy    0   |
</pre>
scales along the two axes of the contour.
In particular, note that
<pre>
|  1    0    0   |
|  0    1    0   |
</pre>
is the identity matrix.

<p>
The "dXformdTheta[][]" is a differential affine matrix 
that is integrated
while the contour is extruded.  Note that this affine
matrix lives in the tangent space, and so it should have the form of 
a generator. Thus,
dx/dt's of the form
<pre>
|  0     r    0   |
|  -r    0    0   |
</pre>
rotate the the contour as it is extruded (r == 0 implies no rotation,
r == 2*PI implies that the contour is rotated once, <i>etc.</i>),
while
<pre>
|  0    0    tx   |
|  0    0    ty   |
</pre>
translates the contour, and 
<pre>
|  sx    0    0   |
|  0    sy    0   |
</pre>
scales it.
In particular, note that
<pre>
|  0    0    0   |
|  0    0    0   |
</pre>
is the identity matrix -- <i>i.e.</i> the derivatives are zero, and therefore
the integral is a constant.
<br>

<img src="candle.gif">

<dt><pre><b> void gleLathe (int ncp,        /* number of contour points */
             gleDouble contour[][2],    /* 2D contour */
             gleDouble cont_normal[][2], /* 2D contour normals */
             gleDouble up[3],           /* up vector for contour */
             gleDouble startRadius,	/* spiral starts in x-y plane */
             gleDouble drdTheta,        /* change in radius per revolution */
             gleDouble startZ,		/* starting z value */
             gleDouble dzdTheta,        /* change in Z per revolution */
             gleDouble startXform[2][3], /* starting contour affine xform */
             gleDouble dXformdTheta[2][3], /* tangent change xform per revoln */
             gleDouble startTheta,	/* start angle in x-y plane */
             gleDouble sweepTheta);	/* degrees to spiral around */
</b></pre>
<dd>
Sweep an arbitrary contour along a helical path. The sweep will be
performed as a shear along the z-axis, so that the orientation of the
contour is displaced, rather than translated, as the contour is swept.
<p>
The axis of the helix lies along the modeling coordinate z-axis.
<p>
An affine transform can be applied as the contour is swept.  For most
ordinary usage, the affines should be given as NULL.
<p>

<img src ="helix1.gif">
<img src ="helix3.gif">
<img src ="helix4.gif">
<img src ="helix5.gif">
<img src ="helix6.gif">
<img src ="helixtex.gif">
<dt><pre><b> void gleHelicoid (gleDouble rToroid, /* circle contour (torus) radius */
             gleDouble startRadius,	/* spiral starts in x-y plane */
             gleDouble drdTheta,        /* change in radius per revolution */
             gleDouble startZ,		/* starting z value */
             gleDouble dzdTheta,        /* change in Z per revolution */
             gleDouble startXform[2][3], /* starting contour affine xform */
             gleDouble dXformdTheta[2][3], /* tangent change xform per revoln */
             gleDouble startTheta,	/* start angle in x-y plane */
             gleDouble sweepTheta);	/* degrees to spiral around */
</b></pre>
<dd> Generalized Torus.
Similar to gleSpiral, except contour is a circle.  Uses gleSpiral to 
draw.

<dt><pre><b> void gleToroid (gleDouble rToroid, /* circle contour (torus) radius */
             gleDouble startRadius,	/* spiral starts in x-y plane */
             gleDouble drdTheta,        /* change in radius per revolution */
             gleDouble startZ,		/* starting z value */
             gleDouble dzdTheta,        /* change in Z per revolution */
             gleDouble startXform[2][3], /* starting contour affine xform */
             gleDouble dXformdTheta[2][3], /* tangent change xform per revoln */
             gleDouble startTheta,	/* start angle in x-y plane */
             gleDouble sweepTheta);	/* degrees to spiral around */
</b></pre>
<dd> Generalized Torus.
Similar to gleLathe, except contour is a circle.  Uses gleLathe to 
draw.

<br>
<img src="screwn.gif">
<img src="screw0.gif">
<img src="screw1.gif">
<img src="screw2.gif">

<dt><pre><b> void gleScrew (int ncp,          /* number of contour points */
             gleDouble contour[][2],    /* 2D contour */
             gleDouble cont_normal[][2], /* 2D contour normals */
             gleDouble up[3],           /* up vector for contour */
             gleDouble startz,          /* start of segment */
             gleDouble endz,            /* end of segment */
             gleDouble twist);          /* number of rotations */
</b></pre>
<dd>Draws screw-type shapes.  Takes a contour, and extrudes it along the
z-axis, from a start z value of <b>startz</b> to an end z-value of
<b>endz</b>.  During the extrusion, it will spin the contour along 
the contour origin by <b>twist</b> degrees.  

</dl>

<h2>GL3.2/IrisGL Subroutines</h2>

This library can be compiled for GL/IrisGL version 3.2 or above, 
or for OpenGL.  The names of the subroutines are different for the 
GL/IrisGL and OpenGL versions. The are:

<dl>
<dt><b> extrusion	</b><dd>gleExtrusion
<dt><b> setjoinstyle	</b><dd>gleSetJoinStyle
<dt><b> getjoinstyle	</b><dd>gleGetJoinStyle
<dt><b> polycone	</b><dd>glePolyCone
<dt><b> polycylinder	</b><dd>glePolyCylinder
<dt><b>	super_extrusion	</b><dd>gleSuperExtrusion
<dt><b>	twist_extrusion	</b><dd>gleTwistExtrusion
<dt><b>	spiral		</b><dd>gleSpiral
<dt><b>	lathe		</b><dd>gleLathe
<dt><b>	helicoid	</b><dd>gleHelicoid
<dt><b>	toroid		</b><dd>gleToroid
<dt><b>	screw		</b><dd>gleScrew
</dl>

<hr>
<h2>Stunts</h2>
For wire-frame mode, try using the glPolygonMode() routine.
<h2> The End </h2>
</body>
</html>