Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
GL_glu.h
Go to the documentation of this file.
1/*
2 * SGI FREE SOFTWARE LICENSE B (Version 2.0, Sept. 18, 2008)
3 * Copyright (C) 1991-2000 Silicon Graphics, Inc. All Rights Reserved.
4 *
5 * Permission is hereby granted, free of charge, to any person obtaining a
6 * copy of this software and associated documentation files (the "Software"),
7 * to deal in the Software without restriction, including without limitation
8 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
9 * and/or sell copies of the Software, and to permit persons to whom the
10 * Software is furnished to do so, subject to the following conditions:
11 *
12 * The above copyright notice including the dates of first publication and
13 * either this permission notice or a reference to
14 * http://oss.sgi.com/projects/FreeB/
15 * shall be included in all copies or substantial portions of the Software.
16 *
17 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
18 * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
19 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
20 * SILICON GRAPHICS, INC. BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
21 * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
22 * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
23 * SOFTWARE.
24 *
25 * Except as contained in this notice, the name of Silicon Graphics, Inc.
26 * shall not be used in advertising or otherwise to promote the sale, use or
27 * other dealings in this Software without prior written authorization from
28 * Silicon Graphics, Inc.
29 */
30
31#ifndef __GL_glu_h__
32#define __GL_glu_h__
33
34/*
35#if defined(USE_MGL_NAMESPACE)
36#include "glu_mangle.h"
37#endif
38
39#include <GL/gl.h>
40*/
41
42#ifndef GLAPIENTRY
43#if defined(_MSC_VER) || defined(__MINGW32__)
44#define GLAPIENTRY __stdcall
45#else
46#define GLAPIENTRY
47#endif
48#endif
49
50#ifndef GLAPIENTRYP
51#define GLAPIENTRYP GLAPIENTRY *
52#endif
53
54// Sergey: we do not want export symbols, all functions for internal use
55#define GLAPI
56
57#ifdef __cplusplus
58extern "C" {
59#endif
60
61/*************************************************************/
62
63/* Extensions */
64#define GLU_EXT_object_space_tess 1
65#define GLU_EXT_nurbs_tessellator 1
66
67/* Boolean */
68#define GLU_FALSE 0
69#define GLU_TRUE 1
70
71/* Version */
72#define GLU_VERSION_1_1 1
73#define GLU_VERSION_1_2 1
74#define GLU_VERSION_1_3 1
75
76/* StringName */
77#define GLU_VERSION 100800
78#define GLU_EXTENSIONS 100801
79
80/* ErrorCode */
81#define GLU_INVALID_ENUM 100900
82#define GLU_INVALID_VALUE 100901
83#define GLU_OUT_OF_MEMORY 100902
84#define GLU_INCOMPATIBLE_GL_VERSION 100903
85#define GLU_INVALID_OPERATION 100904
86
87/* NurbsDisplay */
88/* GLU_FILL */
89#define GLU_OUTLINE_POLYGON 100240
90#define GLU_OUTLINE_PATCH 100241
91
92/* NurbsCallback */
93#define GLU_NURBS_ERROR 100103
94#define GLU_ERROR 100103
95#define GLU_NURBS_BEGIN 100164
96#define GLU_NURBS_BEGIN_EXT 100164
97#define GLU_NURBS_VERTEX 100165
98#define GLU_NURBS_VERTEX_EXT 100165
99#define GLU_NURBS_NORMAL 100166
100#define GLU_NURBS_NORMAL_EXT 100166
101#define GLU_NURBS_COLOR 100167
102#define GLU_NURBS_COLOR_EXT 100167
103#define GLU_NURBS_TEXTURE_COORD 100168
104#define GLU_NURBS_TEX_COORD_EXT 100168
105#define GLU_NURBS_END 100169
106#define GLU_NURBS_END_EXT 100169
107#define GLU_NURBS_BEGIN_DATA 100170
108#define GLU_NURBS_BEGIN_DATA_EXT 100170
109#define GLU_NURBS_VERTEX_DATA 100171
110#define GLU_NURBS_VERTEX_DATA_EXT 100171
111#define GLU_NURBS_NORMAL_DATA 100172
112#define GLU_NURBS_NORMAL_DATA_EXT 100172
113#define GLU_NURBS_COLOR_DATA 100173
114#define GLU_NURBS_COLOR_DATA_EXT 100173
115#define GLU_NURBS_TEXTURE_COORD_DATA 100174
116#define GLU_NURBS_TEX_COORD_DATA_EXT 100174
117#define GLU_NURBS_END_DATA 100175
118#define GLU_NURBS_END_DATA_EXT 100175
119
120/* NurbsError */
121#define GLU_NURBS_ERROR1 100251
122#define GLU_NURBS_ERROR2 100252
123#define GLU_NURBS_ERROR3 100253
124#define GLU_NURBS_ERROR4 100254
125#define GLU_NURBS_ERROR5 100255
126#define GLU_NURBS_ERROR6 100256
127#define GLU_NURBS_ERROR7 100257
128#define GLU_NURBS_ERROR8 100258
129#define GLU_NURBS_ERROR9 100259
130#define GLU_NURBS_ERROR10 100260
131#define GLU_NURBS_ERROR11 100261
132#define GLU_NURBS_ERROR12 100262
133#define GLU_NURBS_ERROR13 100263
134#define GLU_NURBS_ERROR14 100264
135#define GLU_NURBS_ERROR15 100265
136#define GLU_NURBS_ERROR16 100266
137#define GLU_NURBS_ERROR17 100267
138#define GLU_NURBS_ERROR18 100268
139#define GLU_NURBS_ERROR19 100269
140#define GLU_NURBS_ERROR20 100270
141#define GLU_NURBS_ERROR21 100271
142#define GLU_NURBS_ERROR22 100272
143#define GLU_NURBS_ERROR23 100273
144#define GLU_NURBS_ERROR24 100274
145#define GLU_NURBS_ERROR25 100275
146#define GLU_NURBS_ERROR26 100276
147#define GLU_NURBS_ERROR27 100277
148#define GLU_NURBS_ERROR28 100278
149#define GLU_NURBS_ERROR29 100279
150#define GLU_NURBS_ERROR30 100280
151#define GLU_NURBS_ERROR31 100281
152#define GLU_NURBS_ERROR32 100282
153#define GLU_NURBS_ERROR33 100283
154#define GLU_NURBS_ERROR34 100284
155#define GLU_NURBS_ERROR35 100285
156#define GLU_NURBS_ERROR36 100286
157#define GLU_NURBS_ERROR37 100287
158
159/* NurbsProperty */
160#define GLU_AUTO_LOAD_MATRIX 100200
161#define GLU_CULLING 100201
162#define GLU_SAMPLING_TOLERANCE 100203
163#define GLU_DISPLAY_MODE 100204
164#define GLU_PARAMETRIC_TOLERANCE 100202
165#define GLU_SAMPLING_METHOD 100205
166#define GLU_U_STEP 100206
167#define GLU_V_STEP 100207
168#define GLU_NURBS_MODE 100160
169#define GLU_NURBS_MODE_EXT 100160
170#define GLU_NURBS_TESSELLATOR 100161
171#define GLU_NURBS_TESSELLATOR_EXT 100161
172#define GLU_NURBS_RENDERER 100162
173#define GLU_NURBS_RENDERER_EXT 100162
174
175/* NurbsSampling */
176#define GLU_OBJECT_PARAMETRIC_ERROR 100208
177#define GLU_OBJECT_PARAMETRIC_ERROR_EXT 100208
178#define GLU_OBJECT_PATH_LENGTH 100209
179#define GLU_OBJECT_PATH_LENGTH_EXT 100209
180#define GLU_PATH_LENGTH 100215
181#define GLU_PARAMETRIC_ERROR 100216
182#define GLU_DOMAIN_DISTANCE 100217
183
184/* NurbsTrim */
185#define GLU_MAP1_TRIM_2 100210
186#define GLU_MAP1_TRIM_3 100211
187
188/* QuadricDrawStyle */
189#define GLU_POINT 100010
190#define GLU_LINE 100011
191#define GLU_FILL 100012
192#define GLU_SILHOUETTE 100013
193
194/* QuadricCallback */
195/* GLU_ERROR */
196
197/* QuadricNormal */
198#define GLU_SMOOTH 100000
199#define GLU_FLAT 100001
200#define GLU_NONE 100002
201
202/* QuadricOrientation */
203#define GLU_OUTSIDE 100020
204#define GLU_INSIDE 100021
205
206/* TessCallback */
207#define GLU_TESS_BEGIN 100100
208#define GLU_BEGIN 100100
209#define GLU_TESS_VERTEX 100101
210#define GLU_VERTEX 100101
211#define GLU_TESS_END 100102
212#define GLU_END 100102
213#define GLU_TESS_ERROR 100103
214#define GLU_TESS_EDGE_FLAG 100104
215#define GLU_EDGE_FLAG 100104
216#define GLU_TESS_COMBINE 100105
217#define GLU_TESS_BEGIN_DATA 100106
218#define GLU_TESS_VERTEX_DATA 100107
219#define GLU_TESS_END_DATA 100108
220#define GLU_TESS_ERROR_DATA 100109
221#define GLU_TESS_EDGE_FLAG_DATA 100110
222#define GLU_TESS_COMBINE_DATA 100111
223
224/* TessContour */
225#define GLU_CW 100120
226#define GLU_CCW 100121
227#define GLU_INTERIOR 100122
228#define GLU_EXTERIOR 100123
229#define GLU_UNKNOWN 100124
230
231/* TessProperty */
232#define GLU_TESS_WINDING_RULE 100140
233#define GLU_TESS_BOUNDARY_ONLY 100141
234#define GLU_TESS_TOLERANCE 100142
235
236/* TessError */
237#define GLU_TESS_ERROR1 100151
238#define GLU_TESS_ERROR2 100152
239#define GLU_TESS_ERROR3 100153
240#define GLU_TESS_ERROR4 100154
241#define GLU_TESS_ERROR5 100155
242#define GLU_TESS_ERROR6 100156
243#define GLU_TESS_ERROR7 100157
244#define GLU_TESS_ERROR8 100158
245#define GLU_TESS_MISSING_BEGIN_POLYGON 100151
246#define GLU_TESS_MISSING_BEGIN_CONTOUR 100152
247#define GLU_TESS_MISSING_END_POLYGON 100153
248#define GLU_TESS_MISSING_END_CONTOUR 100154
249#define GLU_TESS_COORD_TOO_LARGE 100155
250#define GLU_TESS_NEED_COMBINE_CALLBACK 100156
251
252/* TessWinding */
253#define GLU_TESS_WINDING_ODD 100130
254#define GLU_TESS_WINDING_NONZERO 100131
255#define GLU_TESS_WINDING_POSITIVE 100132
256#define GLU_TESS_WINDING_NEGATIVE 100133
257#define GLU_TESS_WINDING_ABS_GEQ_TWO 100134
258
259
260/* Boolean values */
261#define GL_FALSE 0
262#define GL_TRUE 1
263#define GL_NONE 0
264
265/* Datatypes */
266typedef unsigned int GLenum;
267typedef unsigned char GLboolean;
268typedef unsigned int GLbitfield;
269typedef void GLvoid;
270typedef signed char GLbyte; /* 1-byte signed */
271typedef short GLshort; /* 2-byte signed */
272typedef int GLint; /* 4-byte signed */
273typedef unsigned char GLubyte; /* 1-byte unsigned */
274typedef unsigned short GLushort; /* 2-byte unsigned */
275typedef unsigned int GLuint; /* 4-byte unsigned */
276typedef int GLsizei; /* 4-byte signed */
277typedef float GLfloat; /* single precision float */
278typedef float GLclampf; /* single precision float in [0,1] */
279typedef double GLdouble; /* double precision float */
280typedef double GLclampd; /* double precision float in [0,1] */
281
282/* Primitives */
283#define GL_POINTS 0x0000
284#define GL_LINES 0x0001
285#define GL_LINE_LOOP 0x0002
286#define GL_LINE_STRIP 0x0003
287#define GL_TRIANGLES 0x0004
288#define GL_TRIANGLE_STRIP 0x0005
289#define GL_TRIANGLE_FAN 0x0006
290#define GL_QUADS 0x0007
291#define GL_QUAD_STRIP 0x0008
292#define GL_POLYGON 0x0009
293
294/*************************************************************/
295
296#ifdef __cplusplus
297// struct GLUnurbs;
298// struct GLUquadric;
299struct GLUtesselator;
300#else
301// typedef struct GLUnurbs GLUnurbs;
302// typedef struct GLUquadric GLUquadric;
304#endif
305
306// typedef GLUnurbs GLUnurbsObj;
307// typedef GLUquadric GLUquadricObj;
308// typedef GLUtesselator GLUtesselatorObj;
309// typedef GLUtesselator GLUtriangulatorObj;
310
311#define GLU_TESS_MAX_COORD 1.0e150
312
313/* Internal convenience typedefs */
314typedef void (GLAPIENTRYP _GLUfuncptr)(void);
315
316// GLAPI void GLAPIENTRY gluBeginCurve (GLUnurbs* nurb);
318// GLAPI void GLAPIENTRY gluBeginSurface (GLUnurbs* nurb);
319// GLAPI void GLAPIENTRY gluBeginTrim (GLUnurbs* nurb);
320// GLAPI GLint GLAPIENTRY gluBuild1DMipmapLevels (GLenum target, GLint internalFormat, GLsizei width, GLenum format, GLenum type, GLint level, GLint base, GLint max, const void *data);
321// GLAPI GLint GLAPIENTRY gluBuild1DMipmaps (GLenum target, GLint internalFormat, GLsizei width, GLenum format, GLenum type, const void *data);
322// GLAPI GLint GLAPIENTRY gluBuild2DMipmapLevels (GLenum target, GLint internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum type, GLint level, GLint base, GLint max, const void *data);
323// GLAPI GLint GLAPIENTRY gluBuild2DMipmaps (GLenum target, GLint internalFormat, GLsizei width, GLsizei height, GLenum format, GLenum type, const void *data);
324// GLAPI GLint GLAPIENTRY gluBuild3DMipmapLevels (GLenum target, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, GLint level, GLint base, GLint max, const void *data);
325// GLAPI GLint GLAPIENTRY gluBuild3DMipmaps (GLenum target, GLint internalFormat, GLsizei width, GLsizei height, GLsizei depth, GLenum format, GLenum type, const void *data);
326// GLAPI GLboolean GLAPIENTRY gluCheckExtension (const GLubyte *extName, const GLubyte *extString);
327// GLAPI void GLAPIENTRY gluCylinder (GLUquadric* quad, GLdouble base, GLdouble top, GLdouble height, GLint slices, GLint stacks);
328// GLAPI void GLAPIENTRY gluDeleteNurbsRenderer (GLUnurbs* nurb);
329// GLAPI void GLAPIENTRY gluDeleteQuadric (GLUquadric* quad);
331// GLAPI void GLAPIENTRY gluDisk (GLUquadric* quad, GLdouble inner, GLdouble outer, GLint slices, GLint loops);
332// GLAPI void GLAPIENTRY gluEndCurve (GLUnurbs* nurb);
334// GLAPI void GLAPIENTRY gluEndSurface (GLUnurbs* nurb);
335// GLAPI void GLAPIENTRY gluEndTrim (GLUnurbs* nurb);
336// GLAPI const GLubyte * GLAPIENTRY gluErrorString (GLenum error);
337// GLAPI void GLAPIENTRY gluGetNurbsProperty (GLUnurbs* nurb, GLenum property, GLfloat* data);
338// GLAPI const GLubyte * GLAPIENTRY gluGetString (GLenum name);
340// GLAPI void GLAPIENTRY gluLoadSamplingMatrices (GLUnurbs* nurb, const GLfloat *model, const GLfloat *perspective, const GLint *view);
341// GLAPI void GLAPIENTRY gluLookAt (GLdouble eyeX, GLdouble eyeY, GLdouble eyeZ, GLdouble centerX, GLdouble centerY, GLdouble centerZ, GLdouble upX, GLdouble upY, GLdouble upZ);
342// GLAPI GLUnurbs* GLAPIENTRY gluNewNurbsRenderer (void);
343// GLAPI GLUquadric* GLAPIENTRY gluNewQuadric (void);
346// GLAPI void GLAPIENTRY gluNurbsCallback (GLUnurbs* nurb, GLenum which, _GLUfuncptr CallBackFunc);
347// GLAPI void GLAPIENTRY gluNurbsCallbackData (GLUnurbs* nurb, GLvoid* userData);
348// GLAPI void GLAPIENTRY gluNurbsCallbackDataEXT (GLUnurbs* nurb, GLvoid* userData);
349// GLAPI void GLAPIENTRY gluNurbsCurve (GLUnurbs* nurb, GLint knotCount, GLfloat *knots, GLint stride, GLfloat *control, GLint order, GLenum type);
350// GLAPI void GLAPIENTRY gluNurbsProperty (GLUnurbs* nurb, GLenum property, GLfloat value);
351// GLAPI void GLAPIENTRY gluNurbsSurface (GLUnurbs* nurb, GLint sKnotCount, GLfloat* sKnots, GLint tKnotCount, GLfloat* tKnots, GLint sStride, GLint tStride, GLfloat* control, GLint sOrder, GLint tOrder, GLenum type);
352// GLAPI void GLAPIENTRY gluOrtho2D (GLdouble left, GLdouble right, GLdouble bottom, GLdouble top);
353// GLAPI void GLAPIENTRY gluPartialDisk (GLUquadric* quad, GLdouble inner, GLdouble outer, GLint slices, GLint loops, GLdouble start, GLdouble sweep);
354// GLAPI void GLAPIENTRY gluPerspective (GLdouble fovy, GLdouble aspect, GLdouble zNear, GLdouble zFar);
355// GLAPI void GLAPIENTRY gluPickMatrix (GLdouble x, GLdouble y, GLdouble delX, GLdouble delY, GLint *viewport);
356// GLAPI GLint GLAPIENTRY gluProject (GLdouble objX, GLdouble objY, GLdouble objZ, const GLdouble *model, const GLdouble *proj, const GLint *view, GLdouble* winX, GLdouble* winY, GLdouble* winZ);
357// GLAPI void GLAPIENTRY gluPwlCurve (GLUnurbs* nurb, GLint count, GLfloat* data, GLint stride, GLenum type);
358// GLAPI void GLAPIENTRY gluQuadricCallback (GLUquadric* quad, GLenum which, _GLUfuncptr CallBackFunc);
359// GLAPI void GLAPIENTRY gluQuadricDrawStyle (GLUquadric* quad, GLenum draw);
360// GLAPI void GLAPIENTRY gluQuadricNormals (GLUquadric* quad, GLenum normal);
361// GLAPI void GLAPIENTRY gluQuadricOrientation (GLUquadric* quad, GLenum orientation);
362// GLAPI void GLAPIENTRY gluQuadricTexture (GLUquadric* quad, GLboolean texture);
363// GLAPI GLint GLAPIENTRY gluScaleImage (GLenum format, GLsizei wIn, GLsizei hIn, GLenum typeIn, const void *dataIn, GLsizei wOut, GLsizei hOut, GLenum typeOut, GLvoid* dataOut);
364// GLAPI void GLAPIENTRY gluSphere (GLUquadric* quad, GLdouble radius, GLint slices, GLint stacks);
367GLAPI void GLAPIENTRY gluTessCallback (GLUtesselator* tess, GLenum which, _GLUfuncptr CallBackFunc);
370GLAPI void GLAPIENTRY gluTessNormal (GLUtesselator* tess, GLdouble valueX, GLdouble valueY, GLdouble valueZ);
373// GLAPI GLint GLAPIENTRY gluUnProject (GLdouble winX, GLdouble winY, GLdouble winZ, const GLdouble *model, const GLdouble *proj, const GLint *view, GLdouble* objX, GLdouble* objY, GLdouble* objZ);
374// GLAPI GLint GLAPIENTRY gluUnProject4 (GLdouble winX, GLdouble winY, GLdouble winZ, GLdouble clipW, const GLdouble *model, const GLdouble *proj, const GLint *view, GLdouble nearVal, GLdouble farVal, GLdouble* objX, GLdouble* objY, GLdouble* objZ, GLdouble* objW);
375
376#ifdef __cplusplus
377}
378#endif
379
380#endif /* __GL_glu_h__ */
unsigned char GLubyte
Definition GL_glu.h:273
signed char GLbyte
Definition GL_glu.h:270
unsigned int GLbitfield
Definition GL_glu.h:268
void GLvoid
Definition GL_glu.h:269
GLAPI void GLAPIENTRY gluBeginPolygon(GLUtesselator *tess)
Definition tess.c:621
short GLshort
Definition GL_glu.h:271
float GLfloat
Definition GL_glu.h:277
GLAPI GLUtesselator *GLAPIENTRY gluNewTess(void)
Definition tess.c:102
GLAPI void GLAPIENTRY gluTessEndPolygon(GLUtesselator *tess)
Definition tess.c:510
double GLdouble
Definition GL_glu.h:279
int GLint
Definition GL_glu.h:272
GLAPI void GLAPIENTRY gluTessBeginContour(GLUtesselator *tess)
Definition tess.c:486
#define GLAPIENTRYP
Definition GL_glu.h:51
GLAPI void GLAPIENTRY gluNextContour(GLUtesselator *tess, GLenum type)
Definition tess.c:630
GLAPI void GLAPIENTRY gluTessBeginPolygon(GLUtesselator *tess, GLvoid *data)
Definition tess.c:472
unsigned int GLenum
Definition GL_glu.h:266
GLAPI void GLAPIENTRY gluEndPolygon(GLUtesselator *tess)
Definition tess.c:639
int GLsizei
Definition GL_glu.h:276
GLAPI void GLAPIENTRY gluTessNormal(GLUtesselator *tess, GLdouble valueX, GLdouble valueY, GLdouble valueZ)
Definition tess.c:278
unsigned char GLboolean
Definition GL_glu.h:267
unsigned int GLuint
Definition GL_glu.h:275
#define GLAPIENTRY
Definition GL_glu.h:46
GLAPI void GLAPIENTRY gluTessProperty(GLUtesselator *tess, GLenum which, GLdouble data)
Definition tess.c:211
GLAPI void GLAPIENTRY gluTessCallback(GLUtesselator *tess, GLenum which, _GLUfuncptr CallBackFunc)
Definition tess.c:286
#define GLAPI
Definition GL_glu.h:55
double GLclampd
Definition GL_glu.h:280
GLAPI void GLAPIENTRY gluGetTessProperty(GLUtesselator *tess, GLenum which, GLdouble *data)
Definition tess.c:250
unsigned short GLushort
Definition GL_glu.h:274
float GLclampf
Definition GL_glu.h:278
GLAPI void GLAPIENTRY gluDeleteTess(GLUtesselator *tess)
Definition tess.c:203
GLAPI void GLAPIENTRY gluTessVertex(GLUtesselator *tess, GLdouble *location, GLvoid *data)
Definition tess.c:425
GLAPI void GLAPIENTRY gluTessEndContour(GLUtesselator *tess)
Definition tess.c:503
int type
Definition TGX11.cxx:121
typedef void((*Func_t)())
void * data[4]
Definition tess.h:87