1GLTEXPARAMETER(3G)              [FIXME: manual]             GLTEXPARAMETER(3G)
2
3
4

NAME

6       glTexParameter, glTextureParameter - set texture parameters
7

C SPECIFICATION

9       void glTexParameterf(GLenum target, GLenum pname, GLfloat param);
10
11       void glTexParameteri(GLenum target, GLenum pname, GLint param);
12
13       void glTextureParameterf(GLuint texture, GLenum pname, GLfloat param);
14
15       void glTextureParameteri(GLuint texture, GLenum pname, GLint param);
16
17       void glTexParameterfv(GLenum target, GLenum pname,
18                             const GLfloat * params);
19
20       void glTexParameteriv(GLenum target, GLenum pname,
21                             const GLint * params);
22
23       void glTexParameterIiv(GLenum target, GLenum pname,
24                              const GLint * params);
25
26       void glTexParameterIuiv(GLenum target, GLenum pname,
27                               const GLuint * params);
28
29       void glTextureParameterfv(GLuint texture, GLenum pname,
30                                 const GLfloat *paramtexture.);
31
32       void glTextureParameteriv(GLuint texture, GLenum pname,
33                                 const GLint *param);
34
35       void glTextureParameterIiv(GLuint texture, GLenum pname,
36                                  const GLint *params);
37
38       void glTextureParameterIuiv(GLuint texture, GLenum pname,
39                                   const GLuint *params);
40

PARAMETERS

42       target
43           Specifies the target to which the texture is bound for
44           glTexParameter functions. Must be one of GL_TEXTURE_1D,
45           GL_TEXTURE_1D_ARRAY, GL_TEXTURE_2D, GL_TEXTURE_2D_ARRAY,
46           GL_TEXTURE_2D_MULTISAMPLE, GL_TEXTURE_2D_MULTISAMPLE_ARRAY,
47           GL_TEXTURE_3D, GL_TEXTURE_CUBE_MAP, GL_TEXTURE_CUBE_MAP_ARRAY, or
48           GL_TEXTURE_RECTANGLE.
49
50       texture
51           Specifies the texture object name for glTextureParameter functions.
52
53       pname
54           Specifies the symbolic name of a single-valued texture parameter.
55           pname can be one of the following: GL_DEPTH_STENCIL_TEXTURE_MODE,
56           GL_TEXTURE_BASE_LEVEL, GL_TEXTURE_COMPARE_FUNC,
57           GL_TEXTURE_COMPARE_MODE, GL_TEXTURE_LOD_BIAS,
58           GL_TEXTURE_MIN_FILTER, GL_TEXTURE_MAG_FILTER, GL_TEXTURE_MIN_LOD,
59           GL_TEXTURE_MAX_LOD, GL_TEXTURE_MAX_LEVEL, GL_TEXTURE_SWIZZLE_R,
60           GL_TEXTURE_SWIZZLE_G, GL_TEXTURE_SWIZZLE_B, GL_TEXTURE_SWIZZLE_A,
61           GL_TEXTURE_WRAP_S, GL_TEXTURE_WRAP_T, or GL_TEXTURE_WRAP_R.
62
63           For the vector commands (glTexParameter*v), pname can also be one
64           of GL_TEXTURE_BORDER_COLOR or GL_TEXTURE_SWIZZLE_RGBA.
65
66       param
67           For the scalar commands, specifies the value of pname.
68
69       params
70           For the vector commands, specifies a pointer to an array where the
71           value or values of pname are stored.
72

DESCRIPTION

74       glTexParameter and glTextureParameter assign the value or values in
75       params to the texture parameter specified as pname. For glTexParameter,
76       target defines the target texture, either GL_TEXTURE_1D,
77       GL_TEXTURE_1D_ARRAY, GL_TEXTURE_2D, GL_TEXTURE_2D_ARRAY,
78       GL_TEXTURE_2D_MULTISAMPLE, GL_TEXTURE_2D_MULTISAMPLE_ARRAY,
79       GL_TEXTURE_3D, GL_TEXTURE_CUBE_MAP, GL_TEXTURE_CUBE_MAP_ARRAY, or
80       GL_TEXTURE_RECTANGLE. The following symbols are accepted in pname:
81
82       GL_DEPTH_STENCIL_TEXTURE_MODE
83           Specifies the mode used to read from depth-stencil format textures.
84           params must be one of GL_DEPTH_COMPONENT or GL_STENCIL_COMPONENT.
85           If the depth stencil mode is GL_DEPTH_COMPONENT, then reads from
86           depth-stencil format textures will return the depth component of
87           the texel in Rt and the stencil component will be discarded. If the
88           depth stencil mode is GL_STENCIL_COMPONENT then the stencil
89           component is returned in Rt and the depth component is discarded.
90           The initial value is GL_DEPTH_COMPONENT.
91
92       GL_TEXTURE_BASE_LEVEL
93           Specifies the index of the lowest defined mipmap level. This is an
94           integer value. The initial value is 0.
95
96       GL_TEXTURE_BORDER_COLOR
97           The data in params specifies four values that define the border
98           values that should be used for border texels. If a texel is sampled
99           from the border of the texture, the values of
100           GL_TEXTURE_BORDER_COLOR are interpreted as an RGBA color to match
101           the texture's internal format and substituted for the non-existent
102           texel data. If the texture contains depth components, the first
103           component of GL_TEXTURE_BORDER_COLOR is interpreted as a depth
104           value. The initial value is 0.0 , 0.0 , 0.0 , 0.0.
105
106           If the values for GL_TEXTURE_BORDER_COLOR are specified with
107           glTexParameterIiv or glTexParameterIuiv, the values are stored
108           unmodified with an internal data type of integer. If specified with
109           glTexParameteriv, they are converted to floating point with the
110           following equation: f = 2 c + 1 2 b - 1. If specified with
111           glTexParameterfv, they are stored unmodified as floating-point
112           values.
113
114       GL_TEXTURE_COMPARE_FUNC
115           Specifies the comparison operator used when GL_TEXTURE_COMPARE_MODE
116           is set to GL_COMPARE_REF_TO_TEXTURE. Permissible values are:
117
118           ┌────────────────────┬───────────────────────────────────────────────────────────────────────────────┐
119Texture Comparison Computed result                                                              
120Function            │                                                                               │
121           ├────────────────────┼───────────────────────────────────────────────────────────────────────────────┤
122GL_LEQUAL           │ result                                                                        │
123           │                    │                                                     =                         │
124           │                    │                                                                               │
125           │                    │                                                                               │
126           │                    │                                                                               │
127           │                    │                                                                               │
128           │                    │                                                                     1.0       │
129           │                    │                                                                               │
130           │                    │                                                                               │
131           │                    │                                                                     0.0       │
132           │                    │                                                                               │
133           │                    │                                                                               │
134           │                    │                                                             ⁢                 │
135           │                    │                                                                               │
136           │                    │                                                                               │
137           │                    │                                                                               │
138           │                    │                                                                         r     │
139           │                    │                                                                         <=    │
140           │                    │                                                                               │
141           │                    │                                                                             D │
142           │                    │                                                                             t │
143           │                    │                                                                               │
144           │                    │                                                                               │
145           │                    │                                                                               │
146           │                    │                                                                               │
147           │                    │                                                                               │
148           │                    │                                                                               │
149           │                    │                                                                         r     │
150           │                    │                                                                         >     │
151           │                    │                                                                               │
152           │                    │                                                                             D │
153           │                    │                                                                             t │
154           ├────────────────────┼───────────────────────────────────────────────────────────────────────────────┤
155GL_GEQUAL           │ result                                                                        │
156           │                    │                                                     =                         │
157           │                    │                                                                               │
158           │                    │                                                                               │
159           │                    │                                                                               │
160           │                    │                                                                               │
161           │                    │                                                                     1.0       │
162           │                    │                                                                               │
163           │                    │                                                                               │
164           │                    │                                                                     0.0       │
165           │                    │                                                                               │
166           │                    │                                                                               │
167           │                    │                                                             ⁢                 │
168           │                    │                                                                               │
169           │                    │                                                                               │
170           │                    │                                                                               │
171           │                    │                                                                         r     │
172           │                    │                                                                         >=    │
173           │                    │                                                                               │
174           │                    │                                                                             D │
175           │                    │                                                                             t │
176           │                    │                                                                               │
177           │                    │                                                                               │
178           │                    │                                                                               │
179           │                    │                                                                               │
180           │                    │                                                                               │
181           │                    │                                                                               │
182           │                    │                                                                         r     │
183           │                    │                                                                         <     │
184           │                    │                                                                               │
185           │                    │                                                                             D │
186           │                    │                                                                             t │
187           ├────────────────────┼───────────────────────────────────────────────────────────────────────────────┤
188GL_LESS             │ result                                                                        │
189           │                    │                                                     =                         │
190           │                    │                                                                               │
191           │                    │                                                                               │
192           │                    │                                                                               │
193           │                    │                                                                               │
194           │                    │                                                                     1.0       │
195           │                    │                                                                               │
196           │                    │                                                                               │
197           │                    │                                                                     0.0       │
198           │                    │                                                                               │
199           │                    │                                                                               │
200           │                    │                                                             ⁢                 │
201           │                    │                                                                               │
202           │                    │                                                                               │
203           │                    │                                                                               │
204           │                    │                                                                         r     │
205           │                    │                                                                         <     │
206           │                    │                                                                               │
207           │                    │                                                                             D │
208           │                    │                                                                             t │
209           │                    │                                                                               │
210           │                    │                                                                               │
211           │                    │                                                                               │
212           │                    │                                                                               │
213           │                    │                                                                               │
214           │                    │                                                                               │
215           │                    │                                                                         r     │
216           │                    │                                                                         >=    │
217           │                    │                                                                               │
218           │                    │                                                                             D │
219           │                    │                                                                             t │
220           ├────────────────────┼───────────────────────────────────────────────────────────────────────────────┤
221GL_GREATER          │ result                                                                        │
222           │                    │                                                     =                         │
223           │                    │                                                                               │
224           │                    │                                                                               │
225           │                    │                                                                               │
226           │                    │                                                                               │
227           │                    │                                                                     1.0       │
228           │                    │                                                                               │
229           │                    │                                                                               │
230           │                    │                                                                     0.0       │
231           │                    │                                                                               │
232           │                    │                                                                               │
233           │                    │                                                             ⁢                 │
234           │                    │                                                                               │
235           │                    │                                                                               │
236           │                    │                                                                               │
237           │                    │                                                                         r     │
238           │                    │                                                                         >     │
239           │                    │                                                                               │
240           │                    │                                                                             D │
241           │                    │                                                                             t │
242           │                    │                                                                               │
243           │                    │                                                                               │
244           │                    │                                                                               │
245           │                    │                                                                               │
246           │                    │                                                                               │
247           │                    │                                                                               │
248           │                    │                                                                         r     │
249           │                    │                                                                         <=    │
250           │                    │                                                                               │
251           │                    │                                                                             D │
252           │                    │                                                                             t │
253           ├────────────────────┼───────────────────────────────────────────────────────────────────────────────┤
254GL_EQUAL            │ result                                                                        │
255           │                    │                                                     =                         │
256           │                    │                                                                               │
257           │                    │                                                                               │
258           │                    │                                                                               │
259           │                    │                                                                               │
260           │                    │                                                                     1.0       │
261           │                    │                                                                               │
262           │                    │                                                                               │
263           │                    │                                                                     0.0       │
264           │                    │                                                                               │
265           │                    │                                                                               │
266           │                    │                                                             ⁢                 │
267           │                    │                                                                               │
268           │                    │                                                                               │
269           │                    │                                                                               │
270           │                    │                                                                         r     │
271           │                    │                                                                         =     │
272           │                    │                                                                               │
273           │                    │                                                                             D │
274           │                    │                                                                             t │
275           │                    │                                                                               │
276           │                    │                                                                               │
277           │                    │                                                                               │
278           │                    │                                                                               │
279           │                    │                                                                               │
280           │                    │                                                                               │
281           │                    │                                                                         r     │
282           │                    │                                                                         ≠     │
283           │                    │                                                                               │
284           │                    │                                                                             D │
285           │                    │                                                                             t │
286           ├────────────────────┼───────────────────────────────────────────────────────────────────────────────┤
287GL_NOTEQUAL         │ result                                                                        │
288           │                    │                                                     =                         │
289           │                    │                                                                               │
290           │                    │                                                                               │
291           │                    │                                                                               │
292           │                    │                                                                               │
293           │                    │                                                                     1.0       │
294           │                    │                                                                               │
295           │                    │                                                                               │
296           │                    │                                                                     0.0       │
297           │                    │                                                                               │
298           │                    │                                                                               │
299           │                    │                                                             ⁢                 │
300           │                    │                                                                               │
301           │                    │                                                                               │
302           │                    │                                                                               │
303           │                    │                                                                         r     │
304           │                    │                                                                         ≠     │
305           │                    │                                                                               │
306           │                    │                                                                             D │
307           │                    │                                                                             t │
308           │                    │                                                                               │
309           │                    │                                                                               │
310           │                    │                                                                               │
311           │                    │                                                                               │
312           │                    │                                                                               │
313           │                    │                                                                               │
314           │                    │                                                                         r     │
315           │                    │                                                                         =     │
316           │                    │                                                                               │
317           │                    │                                                                             D │
318           │                    │                                                                             t │
319           ├────────────────────┼───────────────────────────────────────────────────────────────────────────────┤
320GL_ALWAYS           │ result                                                                        │
321           │                    │                                                     =                         │
322           │                    │                                                     1.0                       │
323           ├────────────────────┼───────────────────────────────────────────────────────────────────────────────┤
324GL_NEVER            │ result                                                                        │
325           │                    │                                                     =                         │
326           │                    │                                                     0.0                       │
327           └────────────────────┴───────────────────────────────────────────────────────────────────────────────┘
328           where r is the current interpolated texture coordinate, and D t is
329           the depth texture value sampled from the currently bound depth
330           texture.  result is assigned to the the red channel.
331
332       GL_TEXTURE_COMPARE_MODE
333           Specifies the texture comparison mode for currently bound depth
334           textures. That is, a texture whose internal format is
335           GL_DEPTH_COMPONENT_*; see glTexImage2D()) Permissible values are:
336
337           GL_COMPARE_REF_TO_TEXTURE
338               Specifies that the interpolated and clamped r texture
339               coordinate should be compared to the value in the currently
340               bound depth texture. See the discussion of
341               GL_TEXTURE_COMPARE_FUNC for details of how the comparison is
342               evaluated. The result of the comparison is assigned to the red
343               channel.
344
345           GL_NONE
346               Specifies that the red channel should be assigned the
347               appropriate value from the currently bound depth texture.
348
349
350       GL_TEXTURE_LOD_BIAS
351           params specifies a fixed bias value that is to be added to the
352           level-of-detail parameter for the texture before texture sampling.
353           The specified value is added to the shader-supplied bias value (if
354           any) and subsequently clamped into the implementation-defined range
355           - bias max bias max, where bias max is the value of the
356           implementation defined constant GL_MAX_TEXTURE_LOD_BIAS. The
357           initial value is 0.0.
358
359       GL_TEXTURE_MIN_FILTER
360           The texture minifying function is used whenever the level-of-detail
361           function used when sampling from the texture determines that the
362           texture should be minified. There are six defined minifying
363           functions. Two of them use either the nearest texture elements or a
364           weighted average of multiple texture elements to compute the
365           texture value. The other four use mipmaps.
366
367           A mipmap is an ordered set of arrays representing the same image at
368           progressively lower resolutions. If the texture has dimensions 2 n
369           × 2 m, there are max ⁡ n m + 1 mipmaps. The first mipmap is the
370           original texture, with dimensions 2 n × 2 m. Each subsequent mipmap
371           has dimensions 2 k - 1 × 2 l - 1, where 2 k × 2 l are the
372           dimensions of the previous mipmap, until either k = 0 or l = 0. At
373           that point, subsequent mipmaps have dimension 1 × 2 l - 1 or 2 k -
374           1 × 1 until the final mipmap, which has dimension 1 × 1. To define
375           the mipmaps, call glTexImage1D(), glTexImage2D(), glTexImage3D(),
376           glCopyTexImage1D(), or glCopyTexImage2D() with the level argument
377           indicating the order of the mipmaps. Level 0 is the original
378           texture; level max ⁡ n m is the final 1 × 1 mipmap.
379
380           params supplies a function for minifying the texture as one of the
381           following:
382
383           GL_NEAREST
384               Returns the value of the texture element that is nearest (in
385               Manhattan distance) to the specified texture coordinates.
386
387           GL_LINEAR
388               Returns the weighted average of the four texture elements that
389               are closest to the specified texture coordinates. These can
390               include items wrapped or repeated from other parts of a
391               texture, depending on the values of GL_TEXTURE_WRAP_S and
392               GL_TEXTURE_WRAP_T, and on the exact mapping.
393
394           GL_NEAREST_MIPMAP_NEAREST
395               Chooses the mipmap that most closely matches the size of the
396               pixel being textured and uses the GL_NEAREST criterion (the
397               texture element closest to the specified texture coordinates)
398               to produce a texture value.
399
400           GL_LINEAR_MIPMAP_NEAREST
401               Chooses the mipmap that most closely matches the size of the
402               pixel being textured and uses the GL_LINEAR criterion (a
403               weighted average of the four texture elements that are closest
404               to the specified texture coordinates) to produce a texture
405               value.
406
407           GL_NEAREST_MIPMAP_LINEAR
408               Chooses the two mipmaps that most closely match the size of the
409               pixel being textured and uses the GL_NEAREST criterion (the
410               texture element closest to the specified texture coordinates )
411               to produce a texture value from each mipmap. The final texture
412               value is a weighted average of those two values.
413
414           GL_LINEAR_MIPMAP_LINEAR
415               Chooses the two mipmaps that most closely match the size of the
416               pixel being textured and uses the GL_LINEAR criterion (a
417               weighted average of the texture elements that are closest to
418               the specified texture coordinates) to produce a texture value
419               from each mipmap. The final texture value is a weighted average
420               of those two values.
421
422           As more texture elements are sampled in the minification process,
423           fewer aliasing artifacts will be apparent. While the GL_NEAREST and
424           GL_LINEAR minification functions can be faster than the other four,
425           they sample only one or multiple texture elements to determine the
426           texture value of the pixel being rendered and can produce moire
427           patterns or ragged transitions. The initial value of
428           GL_TEXTURE_MIN_FILTER is GL_NEAREST_MIPMAP_LINEAR.
429
430       GL_TEXTURE_MAG_FILTER
431           The texture magnification function is used whenever the
432           level-of-detail function used when sampling from the texture
433           determines that the texture should be magified. It sets the texture
434           magnification function to either GL_NEAREST or GL_LINEAR (see
435           below).  GL_NEAREST is generally faster than GL_LINEAR, but it can
436           produce textured images with sharper edges because the transition
437           between texture elements is not as smooth. The initial value of
438           GL_TEXTURE_MAG_FILTER is GL_LINEAR.
439
440           GL_NEAREST
441               Returns the value of the texture element that is nearest (in
442               Manhattan distance) to the specified texture coordinates.
443
444           GL_LINEAR
445               Returns the weighted average of the texture elements that are
446               closest to the specified texture coordinates. These can include
447               items wrapped or repeated from other parts of a texture,
448               depending on the values of GL_TEXTURE_WRAP_S and
449               GL_TEXTURE_WRAP_T, and on the exact mapping.
450
451
452       GL_TEXTURE_MIN_LOD
453           Sets the minimum level-of-detail parameter. This floating-point
454           value limits the selection of highest resolution mipmap (lowest
455           mipmap level). The initial value is -1000.
456
457       GL_TEXTURE_MAX_LOD
458           Sets the maximum level-of-detail parameter. This floating-point
459           value limits the selection of the lowest resolution mipmap (highest
460           mipmap level). The initial value is 1000.
461
462       GL_TEXTURE_MAX_LEVEL
463           Sets the index of the highest defined mipmap level. This is an
464           integer value. The initial value is 1000.
465
466       GL_TEXTURE_SWIZZLE_R
467           Sets the swizzle that will be applied to the r component of a texel
468           before it is returned to the shader. Valid values for param are
469           GL_RED, GL_GREEN, GL_BLUE, GL_ALPHA, GL_ZERO and GL_ONE. If
470           GL_TEXTURE_SWIZZLE_R is GL_RED, the value for r will be taken from
471           the first channel of the fetched texel. If GL_TEXTURE_SWIZZLE_R is
472           GL_GREEN, the value for r will be taken from the second channel of
473           the fetched texel. If GL_TEXTURE_SWIZZLE_R is GL_BLUE, the value
474           for r will be taken from the third channel of the fetched texel. If
475           GL_TEXTURE_SWIZZLE_R is GL_ALPHA, the value for r will be taken
476           from the fourth channel of the fetched texel. If
477           GL_TEXTURE_SWIZZLE_R is GL_ZERO, the value for r will be subtituted
478           with 0.0. If GL_TEXTURE_SWIZZLE_R is GL_ONE, the value for r will
479           be subtituted with 1.0. The initial value is GL_RED.
480
481       GL_TEXTURE_SWIZZLE_G
482           Sets the swizzle that will be applied to the g component of a texel
483           before it is returned to the shader. Valid values for param and
484           their effects are similar to those of GL_TEXTURE_SWIZZLE_R. The
485           initial value is GL_GREEN.
486
487       GL_TEXTURE_SWIZZLE_B
488           Sets the swizzle that will be applied to the b component of a texel
489           before it is returned to the shader. Valid values for param and
490           their effects are similar to those of GL_TEXTURE_SWIZZLE_R. The
491           initial value is GL_BLUE.
492
493       GL_TEXTURE_SWIZZLE_A
494           Sets the swizzle that will be applied to the a component of a texel
495           before it is returned to the shader. Valid values for param and
496           their effects are similar to those of GL_TEXTURE_SWIZZLE_R. The
497           initial value is GL_ALPHA.
498
499       GL_TEXTURE_SWIZZLE_RGBA
500           Sets the swizzles that will be applied to the r, g, b, and a
501           components of a texel before they are returned to the shader. Valid
502           values for params and their effects are similar to those of
503           GL_TEXTURE_SWIZZLE_R, except that all channels are specified
504           simultaneously. Setting the value of GL_TEXTURE_SWIZZLE_RGBA is
505           equivalent (assuming no errors are generated) to setting the
506           parameters of each of GL_TEXTURE_SWIZZLE_R, GL_TEXTURE_SWIZZLE_G,
507           GL_TEXTURE_SWIZZLE_B, and GL_TEXTURE_SWIZZLE_A successively.
508
509       GL_TEXTURE_WRAP_S
510           Sets the wrap parameter for texture coordinate s to either
511           GL_CLAMP_TO_EDGE, GL_CLAMP_TO_BORDER, GL_MIRRORED_REPEAT,
512           GL_REPEAT, or GL_MIRROR_CLAMP_TO_EDGE.  GL_CLAMP_TO_EDGE causes s
513           coordinates to be clamped to the range 1 2N 1 - 1 2N, where N is
514           the size of the texture in the direction of clamping.
515           GL_CLAMP_TO_BORDER evaluates s coordinates in a similar manner to
516           GL_CLAMP_TO_EDGE. However, in cases where clamping would have
517           occurred in GL_CLAMP_TO_EDGE mode, the fetched texel data is
518           substituted with the values specified by GL_TEXTURE_BORDER_COLOR.
519           GL_REPEAT causes the integer part of the s coordinate to be
520           ignored; the GL uses only the fractional part, thereby creating a
521           repeating pattern.  GL_MIRRORED_REPEAT causes the s coordinate to
522           be set to the fractional part of the texture coordinate if the
523           integer part of s is even; if the integer part of s is odd, then
524           the s texture coordinate is set to 1 - frac ⁡ s, where frac ⁡ s
525           represents the fractional part of s.  GL_MIRROR_CLAMP_TO_EDGE
526           causes the the s coordinate to be repeated as for
527           GL_MIRRORED_REPEAT for one reptition of the texture, at which point
528           the coordinate to be clamped as in GL_CLAMP_TO_EDGE. Initially,
529           GL_TEXTURE_WRAP_S is set to GL_REPEAT.
530
531       GL_TEXTURE_WRAP_T
532           Sets the wrap parameter for texture coordinate t to either
533           GL_CLAMP_TO_EDGE, GL_CLAMP_TO_BORDER, GL_MIRRORED_REPEAT,
534           GL_REPEAT, or GL_MIRROR_CLAMP_TO_EDGE. See the discussion under
535           GL_TEXTURE_WRAP_S. Initially, GL_TEXTURE_WRAP_T is set to
536           GL_REPEAT.
537
538       GL_TEXTURE_WRAP_R
539           Sets the wrap parameter for texture coordinate r to either
540           GL_CLAMP_TO_EDGE, GL_CLAMP_TO_BORDER, GL_MIRRORED_REPEAT,
541           GL_REPEAT, or GL_MIRROR_CLAMP_TO_EDGE. See the discussion under
542           GL_TEXTURE_WRAP_S. Initially, GL_TEXTURE_WRAP_R is set to
543           GL_REPEAT.
544

NOTES

546       Suppose that a program attempts to sample from a texture and has set
547       GL_TEXTURE_MIN_FILTER to one of the functions that requires a mipmap.
548       If either the dimensions of the texture images currently defined (with
549       previous calls to glTexImage1D(), glTexImage2D(), glTexImage3D(),
550       glCopyTexImage1D(), or glCopyTexImage2D()) do not follow the proper
551       sequence for mipmaps (described above), or there are fewer texture
552       images defined than are needed, or the set of texture images have
553       differing numbers of texture components, then the texture is considered
554       incomplete.
555
556       Linear filtering accesses the four nearest texture elements only in 2D
557       textures. In 1D textures, linear filtering accesses the two nearest
558       texture elements. In 3D textures, linear filtering accesses the eight
559       nearest texture elements.
560
561       glTexParameter specifies the texture parameters for the active texture
562       unit, specified by calling glActiveTexture().  glTextureParameter
563       specifies the texture parameters for the texture object with ID
564       texture.
565
566       GL_DEPTH_STENCIL_TEXTURE_MODE is available only if the GL version is
567       4.3 or greater.
568
569       GL_MIRROR_CLAMP_TO_EDGE is available only if the GL version is 4.4 or
570       greater.
571

ERRORS

573       GL_INVALID_ENUM is generated by glTexParameter if target is not one of
574       the accepted defined values.
575
576       GL_INVALID_ENUM is generated if pname is not one of the accepted
577       defined values.
578
579       GL_INVALID_ENUM is generated if params should have a defined constant
580       value (based on the value of pname) and does not.
581
582       GL_INVALID_ENUM is generated if glTexParameter{if} or
583       glTextureParameter{if} is called for a non-scalar parameter (pname
584       GL_TEXTURE_BORDER_COLOR or GL_TEXTURE_SWIZZLE_RGBA).
585
586       GL_INVALID_ENUM is generated if the effective target is either
587       GL_TEXTURE_2D_MULTISAMPLE or GL_TEXTURE_2D_MULTISAMPLE_ARRAY, and pname
588       is any of the sampler states.
589
590       GL_INVALID_ENUM is generated if the effective target is
591       GL_TEXTURE_RECTANGLE and either of pnames GL_TEXTURE_WRAP_S or
592       GL_TEXTURE_WRAP_T is set to either GL_MIRROR_CLAMP_TO_EDGE,
593       GL_MIRRORED_REPEAT or GL_REPEAT.
594
595       GL_INVALID_ENUM is generated if the effective target is
596       GL_TEXTURE_RECTANGLE and pname GL_TEXTURE_MIN_FILTER is set to a value
597       other than GL_NEAREST or GL_LINEAR (no mipmap filtering is permitted).
598
599       GL_INVALID_OPERATION is generated if the effective target is either
600       GL_TEXTURE_2D_MULTISAMPLE or GL_TEXTURE_2D_MULTISAMPLE_ARRAY, and pname
601       GL_TEXTURE_BASE_LEVEL is set to a value other than zero.
602
603       GL_INVALID_OPERATION is generated by glTextureParameter if texture is
604       not the name of an existing texture object.
605
606       GL_INVALID_OPERATION is generated if the effective target is
607       GL_TEXTURE_RECTANGLE and pname GL_TEXTURE_BASE_LEVEL is set to any
608       value other than zero.
609
610       GL_INVALID_VALUE is generated if pname is GL_TEXTURE_BASE_LEVEL or
611       GL_TEXTURE_MAX_LEVEL, and param or params is negative.
612

ASSOCIATED GETS

614       glGetTexParameter()
615
616       glGetTextureParameter
617
618       glGetTexLevelParameter()
619
620       glGetTextureLevelParameter
621

VERSION SUPPORT

623       ┌───────────────────────┬───────────────────────────────────────────────────────────────────────┐
624       │                       │                OpenGL Version                                         
625       ├───────────────────────┼─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┬─────┤
626Function               2.0 2.1 3.0 3.1 3.2 3.3 4.0 4.1 4.2 4.3 4.4 4.5 
627/                      │     │     │     │     │     │     │     │     │     │     │     │     │
628Feature                │     │     │     │     │     │     │     │     │     │     │     │     │
629Name                   │     │     │     │     │     │     │     │     │     │     │     │     │
630       ├───────────────────────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
631glTexParameterIiv      │  -  │  -  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │
632       ├───────────────────────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
633glTexParameterIuiv     │  -  │  -  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │
634       ├───────────────────────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
635glTexParameterf        │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │
636       ├───────────────────────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
637glTexParameterfv       │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │
638       ├───────────────────────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
639glTexParameteri        │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │
640       ├───────────────────────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
641glTexParameteriv       │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │  ✔  │
642       ├───────────────────────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
643glTextureParameterIiv  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  ✔  │
644       ├───────────────────────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
645glTextureParameterIuiv │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  ✔  │
646       ├───────────────────────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
647glTextureParameterf    │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  ✔  │
648       ├───────────────────────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
649glTextureParameterfv   │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  ✔  │
650       ├───────────────────────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
651glTextureParameteri    │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  ✔  │
652       ├───────────────────────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┼─────┤
653glTextureParameteriv   │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  -  │  ✔  │
654       └───────────────────────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┴─────┘
655

SEE ALSO

657       glActiveTexture(), glBindTexture(), glCopyTexImage1D(),
658       glCopyTexImage2D(), glCopyTexSubImage1D(), glCopyTexSubImage2D(),
659       glCopyTexSubImage3D(), glPixelStore(), glSamplerParameter(),
660       glTexImage1D(), glTexImage2D(), glTexImage3D(), glTexSubImage1D(),
661       glTexSubImage2D(), glTexSubImage3D()
662
664       Copyright © 1991-2006 Silicon Graphics, Inc. Copyright © 2012-2014
665       Khronos Group. This document is licensed under the SGI Free Software B
666       License. For details, see http://oss.sgi.com/projects/FreeB/.
667
669       Copyright © 1991-2006 Silicon Graphics, Inc.
670       Copyright © 2012-2014 Khronos Group
671
672
673
674[FIXME: source]                   07/13/2018                GLTEXPARAMETER(3G)
Impressum