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
|
<?xml version="1.0" encoding="utf-8" ?>
<!DOCTYPE erlref SYSTEM "erlref.dtd">
<!-- THIS FILE IS GENERATED DO NOT EDIT -->
<erlref>
<header>
<copyright>
<year>2020</year>
<holder>Ericsson AB. All Rights Reserved.</holder></copyright>
<legalnotice>
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
</legalnotice>
<title>glu</title>
</header>
<module>glu</module>
<modulesummary>Erlang wrapper functions for OpenGL</modulesummary>
<description><p>Standard OpenGL API</p><p>This documents the functions as a brief version of the complete <url href="https://www.khronos.org/registry/OpenGL-Refpages/">OpenGL reference pages.</url></p></description>
<datatypes>
<datatype><name name="vertex"/></datatype>
<datatype><name name="i"/></datatype>
<datatype><name name="f"/></datatype>
<datatype><name name="enum"/></datatype>
<datatype><name name="matrix"/></datatype>
<datatype><name name="m12"/></datatype>
<datatype><name name="m16"/></datatype>
<datatype><name name="mem"/></datatype></datatypes>
<funcs>
<func>
<name name="build1DMipmapLevels" arity="9" clause_i="1" since=""/>
<fsummary>builds a subset of one-dimensional mipmap levels</fsummary>
<desc>
<p><seemfa marker="glu#build1DMipmapLevels/9"><c>glu:build1DMipmapLevels/9</c></seemfa> builds a subset of prefiltered one-dimensional texture maps of decreasing resolutions called a mipmap. This is used for the antialiasing of texture mapped primitives. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluBuild1DMipmapLevels.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="build1DMipmaps" arity="6" clause_i="1" since=""/>
<fsummary>builds a one-dimensional mipmap</fsummary>
<desc>
<p><seemfa marker="glu#build1DMipmaps/6"><c>glu:build1DMipmaps/6</c></seemfa> builds a series of prefiltered one-dimensional texture maps of decreasing resolutions called a mipmap. This is used for the antialiasing of texture mapped primitives. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluBuild1DMipmaps.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="build2DMipmapLevels" arity="10" clause_i="1" since=""/>
<fsummary>builds a subset of two-dimensional mipmap levels</fsummary>
<desc>
<p><seemfa marker="glu#build2DMipmapLevels/10"><c>glu:build2DMipmapLevels/10</c></seemfa> builds a subset of prefiltered two-dimensional texture maps of decreasing resolutions called a mipmap. This is used for the antialiasing of texture mapped primitives. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluBuild2DMipmapLevels.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="build2DMipmaps" arity="7" clause_i="1" since=""/>
<fsummary>builds a two-dimensional mipmap</fsummary>
<desc>
<p><seemfa marker="glu#build2DMipmaps/7"><c>glu:build2DMipmaps/7</c></seemfa> builds a series of prefiltered two-dimensional texture maps of decreasing resolutions called a mipmap. This is used for the antialiasing of texture-mapped primitives. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluBuild2DMipmaps.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="build3DMipmapLevels" arity="11" clause_i="1" since=""/>
<fsummary>builds a subset of three-dimensional mipmap levels</fsummary>
<desc>
<p><seemfa marker="glu#build3DMipmapLevels/11"><c>glu:build3DMipmapLevels/11</c></seemfa> builds a subset of prefiltered three-dimensional texture maps of decreasing resolutions called a mipmap. This is used for the antialiasing of texture mapped primitives. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluBuild3DMipmapLevels.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="build3DMipmaps" arity="8" clause_i="1" since=""/>
<fsummary>builds a three-dimensional mipmap</fsummary>
<desc>
<p><seemfa marker="glu#build3DMipmaps/8"><c>glu:build3DMipmaps/8</c></seemfa> builds a series of prefiltered three-dimensional texture maps of decreasing resolutions called a mipmap. This is used for the antialiasing of texture-mapped primitives. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluBuild3DMipmaps.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="checkExtension" arity="2" clause_i="1" since=""/>
<fsummary>determines if an extension name is supported</fsummary>
<desc>
<p><seemfa marker="glu#checkExtension/2"><c>glu:checkExtension/2</c></seemfa> returns <c>?GLU_TRUE</c> if <c>ExtName</c> is supported otherwise <c>?GLU_FALSE</c> is returned. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluCheckExtension.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="cylinder" arity="6" clause_i="1" since=""/>
<fsummary>draw a cylinder</fsummary>
<desc>
<p><seemfa marker="glu#cylinder/6"><c>glu:cylinder/6</c></seemfa> draws a cylinder oriented along the <c>z</c> axis. The base of the cylinder is placed at <c>z</c> = 0 and the top at z=height. Like a sphere, a cylinder is subdivided around the <c>z</c> axis into slices and along the <c>z</c> axis into stacks. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluCylinder.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="deleteQuadric" arity="1" clause_i="1" since=""/>
<fsummary>destroy a quadrics object</fsummary>
<desc>
<p><seemfa marker="glu#deleteQuadric/1"><c>glu:deleteQuadric/1</c></seemfa> destroys the quadrics object (created with <seemfa marker="glu#newQuadric/0"><c>glu:newQuadric/0</c></seemfa>) and frees any memory it uses. Once <seemfa marker="glu#deleteQuadric/1"><c>glu:deleteQuadric/1</c></seemfa> has been called, <c>Quad</c> cannot be used again. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluDeleteQuadric.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="disk" arity="5" clause_i="1" since=""/>
<fsummary>draw a disk</fsummary>
<desc>
<p><seemfa marker="glu#disk/5"><c>glu:disk/5</c></seemfa> renders a disk on the <c>z</c> = 0 plane. The disk has a radius of <c>Outer</c> and contains a concentric circular hole with a radius of <c>Inner</c>. If <c>Inner</c> is 0, then no hole is generated. The disk is subdivided around the <c>z</c> axis into slices (like pizza slices) and also about the <c>z</c> axis into rings (as specified by <c>Slices</c> and <c>Loops</c>, respectively). </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluDisk.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="errorString" arity="1" clause_i="1" since=""/>
<fsummary>produce an error string from a GL or GLU error code</fsummary>
<desc>
<p><seemfa marker="glu#errorString/1"><c>glu:errorString/1</c></seemfa> produces an error string from a GL or GLU error code. The string is in ISO Latin 1 format. For example, <seemfa marker="glu#errorString/1"><c>glu:errorString/1</c></seemfa>(<c>?GLU_OUT_OF_MEMORY</c>) returns the string <c>out of memory</c>. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluErrorString.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="getString" arity="1" clause_i="1" since=""/>
<fsummary>return a string describing the GLU version or GLU extensions </fsummary>
<desc>
<p><seemfa marker="glu#getString/1"><c>glu:getString/1</c></seemfa> returns a pointer to a static string describing the GLU version or the GLU extensions that are supported. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluGetString.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="lookAt" arity="9" clause_i="1" since=""/>
<fsummary>define a viewing transformation</fsummary>
<desc>
<p><seemfa marker="glu#lookAt/9"><c>glu:lookAt/9</c></seemfa> creates a viewing matrix derived from an eye point, a reference point indicating the center of the scene, and an <c>UP</c> vector. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluLookAt.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="newQuadric" arity="0" clause_i="1" since=""/>
<fsummary>create a quadrics object</fsummary>
<desc>
<p><seemfa marker="glu#newQuadric/0"><c>glu:newQuadric/0</c></seemfa> creates and returns a pointer to a new quadrics object. This object must be referred to when calling quadrics rendering and control functions. A return value of 0 means that there is not enough memory to allocate the object. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluNewQuadric.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="ortho2D" arity="4" clause_i="1" since=""/>
<fsummary>define a 2D orthographic projection matrix</fsummary>
<desc>
<p><seemfa marker="glu#ortho2D/4"><c>glu:ortho2D/4</c></seemfa> sets up a two-dimensional orthographic viewing region. This is equivalent to calling <seemfa marker="gl#ortho/6"><c>gl:ortho/6</c></seemfa> with near=-1 and far=1. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluOrtho2D.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="partialDisk" arity="7" clause_i="1" since=""/>
<fsummary>draw an arc of a disk</fsummary>
<desc>
<p><seemfa marker="glu#partialDisk/7"><c>glu:partialDisk/7</c></seemfa> renders a partial disk on the z=0 plane. A partial disk is similar to a full disk, except that only the subset of the disk from <c>Start</c> through <c>Start</c> + <c>Sweep</c> is included (where 0 degrees is along the +f2yf axis, 90 degrees along the +<c>x</c> axis, 180 degrees along the -<c>y</c> axis, and 270 degrees along the -<c>x</c> axis). </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluPartialDisk.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="perspective" arity="4" clause_i="1" since=""/>
<fsummary>set up a perspective projection matrix</fsummary>
<desc>
<p><seemfa marker="glu#perspective/4"><c>glu:perspective/4</c></seemfa> specifies a viewing frustum into the world coordinate system. In general, the aspect ratio in <seemfa marker="glu#perspective/4"><c>glu:perspective/4</c></seemfa> should match the aspect ratio of the associated viewport. For example, aspect=2.0 means the viewer's angle of view is twice as wide in <c>x</c> as it is in <c>y</c>. If the viewport is twice as wide as it is tall, it displays the image without distortion. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluPerspective.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="pickMatrix" arity="5" clause_i="1" since=""/>
<fsummary>define a picking region</fsummary>
<desc>
<p><seemfa marker="glu#pickMatrix/5"><c>glu:pickMatrix/5</c></seemfa> creates a projection matrix that can be used to restrict drawing to a small region of the viewport. This is typically useful to determine what objects are being drawn near the cursor. Use <seemfa marker="glu#pickMatrix/5"><c>glu:pickMatrix/5</c></seemfa> to restrict drawing to a small region around the cursor. Then, enter selection mode (with <seemfa marker="gl#renderMode/1"><c>gl:renderMode/1</c></seemfa>) and rerender the scene. All primitives that would have been drawn near the cursor are identified and stored in the selection buffer. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluPickMatrix.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="project" arity="6" clause_i="1" since=""/>
<fsummary>map object coordinates to window coordinates</fsummary>
<desc>
<p><seemfa marker="glu#project/6"><c>glu:project/6</c></seemfa> transforms the specified object coordinates into window coordinates using <c>Model</c>, <c>Proj</c>, and <c>View</c>. The result is stored in <c>WinX</c>, <c>WinY</c>, and <c>WinZ</c>. A return value of <c>?GLU_TRUE</c> indicates success, a return value of <c>?GLU_FALSE</c> indicates failure. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluProject.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="quadricDrawStyle" arity="2" clause_i="1" since=""/>
<fsummary>specify the draw style desired for quadrics</fsummary>
<desc>
<p><seemfa marker="glu#quadricDrawStyle/2"><c>glu:quadricDrawStyle/2</c></seemfa> specifies the draw style for quadrics rendered with <c>Quad</c>. The legal values are as follows: </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluQuadricDrawStyle.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="quadricNormals" arity="2" clause_i="1" since=""/>
<fsummary>specify what kind of normals are desired for quadrics</fsummary>
<desc>
<p><seemfa marker="glu#quadricNormals/2"><c>glu:quadricNormals/2</c></seemfa> specifies what kind of normals are desired for quadrics rendered with <c>Quad</c>. The legal values are as follows: </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluQuadricNormals.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="quadricOrientation" arity="2" clause_i="1" since=""/>
<fsummary>specify inside/outside orientation for quadrics</fsummary>
<desc>
<p><seemfa marker="glu#quadricOrientation/2"><c>glu:quadricOrientation/2</c></seemfa> specifies what kind of orientation is desired for quadrics rendered with <c>Quad</c>. The <c>Orientation</c> values are as follows: </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluQuadricOrientation.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="quadricTexture" arity="2" clause_i="1" since=""/>
<fsummary>specify if texturing is desired for quadrics</fsummary>
<desc>
<p><seemfa marker="glu#quadricTexture/2"><c>glu:quadricTexture/2</c></seemfa> specifies if texture coordinates should be generated for quadrics rendered with <c>Quad</c>. If the value of <c>Texture</c> is <c>?GLU_TRUE</c>, then texture coordinates are generated, and if <c>Texture</c> is <c>?GLU_FALSE</c>, they are not. The initial value is <c>?GLU_FALSE</c>. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluQuadricTexture.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="scaleImage" arity="9" clause_i="1" since=""/>
<fsummary>scale an image to an arbitrary size</fsummary>
<desc>
<p><seemfa marker="glu#scaleImage/9"><c>glu:scaleImage/9</c></seemfa> scales a pixel image using the appropriate pixel store modes to unpack data from the source image and pack data into the destination image. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluScaleImage.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="sphere" arity="4" clause_i="1" since=""/>
<fsummary>draw a sphere</fsummary>
<desc>
<p><seemfa marker="glu#sphere/4"><c>glu:sphere/4</c></seemfa> draws a sphere of the given radius centered around the origin. The sphere is subdivided around the <c>z</c> axis into slices and along the <c>z</c> axis into stacks (similar to lines of longitude and latitude). </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluSphere.xml">External documentation.</url></p></desc>
</func>
<func>
<name name="tesselate" arity="2" clause_i="1" since=""/>
<fsummary>triangulate a face</fsummary>
<desc><p>Triangulates a polygon, the polygon is specified by a <c>Normal</c> and <c>Vs</c> a list of vertex positions. </p><p>The function returns a list of indices of the vertices and a binary (64bit native float) containing an array of vertex positions, it starts with the vertices in <c>Vs</c> and may contain newly created vertices in the end.</p></desc>
</func>
<func>
<name name="unProject" arity="6" clause_i="1" since=""/>
<name name="unProject4" arity="9" clause_i="1" since=""/>
<fsummary>map window coordinates to object coordinates</fsummary>
<desc>
<p><seemfa marker="glu#unProject/6"><c>glu:unProject/6</c></seemfa> maps the specified window coordinates into object coordinates using <c>Model</c>, <c>Proj</c>, and <c>View</c>. The result is stored in <c>ObjX</c>, <c>ObjY</c>, and <c>ObjZ</c>. A return value of <c>?GLU_TRUE</c> indicates success; a return value of <c>?GLU_FALSE</c> indicates failure. </p>
<p><url href="https://www.khronos.org/registry/OpenGL-Refpages/gl2.1/xhtml/gluUnProject.xml">External documentation.</url></p></desc>
</func></funcs>
</erlref>
|