GLTEXPARAMETER(3G)

πŸ“¦
version 1.1 Β· 3 versions
, in centos-stream 9

okay bestie, welcome to the GLTEXPARAMETER(3G) page β€” yes, that's the 3G manual, and the raw header has a little [FIXME: manual] moment going on. We're not gonna let that kill the vibe. This is the texture-parameter glow-up, and it's lowkey important.

πŸ’– NAME πŸ’–

glTexParameter, glTextureParameter β€” set texture parameters.


πŸŽ€ C SPECIFICATION πŸŽ€

void glTexParameterf(GLenum target, GLenum pname, GLfloat param);

void glTexParameteri(GLenum target, GLenum pname, GLint param);

void glTextureParameterf(GLuint texture, GLenum pname, GLfloat param);

void glTextureParameteri(GLuint texture, GLenum pname, GLint param);

void glTexParameterfv(GLenum target, GLenum pname,
                      const GLfloat * params);

void glTexParameteriv(GLenum target, GLenum pname,
                      const GLint * params);

void glTexParameterIiv(GLenum target, GLenum pname,
                       const GLint * params);

void glTexParameterIuiv(GLenum target, GLenum pname,
                        const GLuint * params);

void glTextureParameterfv(GLuint texture, GLenum pname,
                          const GLfloat *params);

void glTextureParameteriv(GLuint texture, GLenum pname,
                          const GLint *params);

void glTextureParameterIiv(GLuint texture, GLenum pname,
                           const GLint *params);

void glTextureParameterIuiv(GLuint texture, GLenum pname,
                            const GLuint *params);

✨ PARAMETERS ✨

  • target β€” the target the texture is bound to for the glTexParameter functions. Bestie, it must be one of: GL_TEXTURE_1D, GL_TEXTURE_1D_ARRAY, GL_TEXTURE_2D, GL_TEXTURE_2D_ARRAY, GL_TEXTURE_2D_MULTISAMPLE, GL_TEXTURE_2D_MULTISAMPLE_ARRAY, GL_TEXTURE_3D, GL_TEXTURE_CUBE_MAP, GL_TEXTURE_CUBE_MAP_ARRAY, or GL_TEXTURE_RECTANGLE.
  • texture β€” the texture object name for the glTextureParameter functions. Iconic little handle, no cap.
  • pname β€” the symbolic name of a single-valued texture parameter. pname can be one of: GL_DEPTH_STENCIL_TEXTURE_MODE, GL_TEXTURE_BASE_LEVEL, GL_TEXTURE_COMPARE_FUNC, GL_TEXTURE_COMPARE_MODE, GL_TEXTURE_LOD_BIAS, GL_TEXTURE_MIN_FILTER, GL_TEXTURE_MAG_FILTER, GL_TEXTURE_MIN_LOD, GL_TEXTURE_MAX_LOD, GL_TEXTURE_MAX_LEVEL, GL_TEXTURE_SWIZZLE_R, GL_TEXTURE_SWIZZLE_G, GL_TEXTURE_SWIZZLE_B, GL_TEXTURE_SWIZZLE_A, GL_TEXTURE_WRAP_S, GL_TEXTURE_WRAP_T, or GL_TEXTURE_WRAP_R.

For the vector commands (glTexParameter*v), pname can also be one of GL_TEXTURE_BORDER_COLOR or GL_TEXTURE_SWIZZLE_RGBA. Periodt.

  • param β€” for the scalar commands, this specifies the value of pname.
  • params β€” for the vector commands, this is a pointer to an array where the value or values of pname are stored.

πŸ¦‹ DESCRIPTION πŸ¦‹

glTexParameter and glTextureParameter assign the value or values in params to the texture parameter specified as pname. For glTexParameter, target defines the target texture, either GL_TEXTURE_1D, GL_TEXTURE_1D_ARRAY, GL_TEXTURE_2D, GL_TEXTURE_2D_ARRAY, GL_TEXTURE_2D_MULTISAMPLE, GL_TEXTURE_2D_MULTISAMPLE_ARRAY, GL_TEXTURE_3D, GL_TEXTURE_CUBE_MAP, GL_TEXTURE_CUBE_MAP_ARRAY, or GL_TEXTURE_RECTANGLE.

The following symbols are accepted in pname:

  • GL_DEPTH_STENCIL_TEXTURE_MODE β€” specifies the mode used to read from depth-stencil format textures. params must be one of GL_DEPTH_COMPONENT or GL_STENCIL_COMPONENT. If the depth stencil mode is GL_DEPTH_COMPONENT, then reads from depth-stencil format textures will return the depth component of the texel in Rt and the stencil component will be discarded. If the depth stencil mode is GL_STENCIL_COMPONENT then the stencil component is returned in Rt and the depth component is discarded. The initial value is GL_DEPTH_COMPONENT.
  • GL_TEXTURE_BASE_LEVEL β€” specifies the index of the lowest defined mipmap level. This is an integer value. The initial value is 0.
  • GL_TEXTURE_BORDER_COLOR β€” the data in params specifies four values that define the border values that should be used for border texels. If a texel is sampled from the border of the texture, the values of GL_TEXTURE_BORDER_COLOR are interpreted as an RGBA color to match the texture's internal format and substituted for the non-existent texel data. If the texture contains depth components, the first component of GL_TEXTURE_BORDER_COLOR is interpreted as a depth value. The initial value is 0.0 , 0.0 , 0.0 , 0.0.

If the values for GL_TEXTURE_BORDER_COLOR are specified with glTexParameterIiv or glTexParameterIuiv, the values are stored unmodified with an internal data type of integer. If specified with glTexParameteriv, they are converted to floating point with the following equation: f = 2 c + 1 2 b - 1. If specified with glTexParameterfv, they are stored unmodified as floating-point values.

GL_TEXTURE_COMPARE_FUNC β€” okay so this parameter specifies the comparison operator used when GL_TEXTURE_COMPARE_MODE is set to GL_COMPARE_REF_TO_TEXTURE. πŸ’… The table’s two columns are Texture Comparison Function and Computed result, and the permissible values are:

  • GL_LEQUAL β€” result is the step between 1.0 and 0.0: result = 1.0 on the r <= D_t branch, and result = 0.0 on the r > D_t branch. ✨ The little graph is plotting result against r, with D_t marked on the axis.
  • GL_GEQUAL β€” flipped comparison energy: result = 1.0 on the r >= D_t branch, and result = 0.0 on the r < D_t branch. 🌸 The graph labels r, D_t, 1.0, and 0.0, no cap.
  • GL_LESS β€” the Computed result cell shows result with the 1.0 / 0.0 step, and the comparison marked r < D_t with D_t on the axis. πŸ¦‹ This row is mid-drawing in this chunk, so its graph keeps going past what’s shown here.

ok so now we hit the ✨graph era✨ of this page and honestly? it's giving math-class-but-make-it-couture πŸ“ˆπŸ’… This whole stretch is a big table, and the left column is the parameter name while the right column is a little graph showing result on the vertical axis β€” it runs from 1.0 at the top down to 0.0 at the bottom β€” plotted against r on the horizontal axis, with Dt marked there too. Every row also has those cute little comparison labels like r >= Dt scribbled on the curve, so you can tell which shape you're looking at. iykyk πŸ”₯

fair warning bestie: these tables are wide, and my redraw here keeps every label but loses some of the original's vertical bar padding so it doesn't eat your whole terminal 😭 nothing is missing, i promise 🫢

🌈 GL_GREATER

The graph for this one is labeled with all three of these:

GL_GREATER   result
             1.0
             0.0
             r >= Dt
             r >  Dt
             r <= Dt

Vertical axis: result, topping out at 1.0 and bottoming out at 0.0. Horizontal axis: r, with Dt on it. The three operator labels sit on the curves, so you can see exactly which shape goes with which comparison. slay πŸŽ€

πŸ¦‹ GL_EQUAL

Same axis situation β€” result up the side from 1.0 to 0.0, r along the bottom with Dt β€” but the curve labels are these two:

GL_EQUAL     result
             1.0
             0.0
             r = Dt
             r β‰  Dt

yep, that's the equals one and the not-equals one living in the same row, iconic behavior honestly πŸ‘‘

πŸ’œ GL_NOTEQUAL

and then this row starts up:

GL_NOTEQUAL  result
             1.0
             0.0

…aaaand that's exactly where this chunk of the table cuts off in my copy 😭 the graphs keep going in the next bit, don't panic, we're not done β€” the table literally just keeps rolling and there's more coming fr fr πŸ§šπŸ’–

  • GL_NOTEQUAL β€” result = 1.0 if r β‰  Dt, 0.0 otherwise. (the "not equal" vibe πŸ’…)
  • GL_EQUAL β€” result = 1.0 if r = Dt, 0.0 otherwise. (matchy-matchy ✨)
  • GL_ALWAYS β€” result = 1.0. (always slaying πŸ”₯)
  • GL_NEVER β€” result = 0.0. (never beating the allegations πŸ’€)

where r is the current interpolated texture coordinate, and Dt is the depth texture value sampled from the currently bound depth texture. result is assigned to the red channel. (red channel main character energy πŸ‘‘)

πŸŽ€ GL_TEXTURE_COMPARE_MODE πŸŽ€

Specifies the texture comparison mode for currently bound depth textures. That is, a texture whose internal format is GL_DEPTH_COMPONENT_*; see glTexImage2D(). Permissible values are:

  • GL_COMPARE_REF_TO_TEXTURE β€” Specifies that the interpolated and clamped r texture coordinate should be compared to the value in the currently bound depth texture. See the discussion of GL_TEXTURE_COMPARE_FUNC for details of how the comparison is evaluated. The result of the comparison is assigned to the red channel. (so it's like a little referee for your depth values πŸ§‘β€βš–οΈ)
  • GL_NONE β€” Specifies that the red channel should be assigned the appropriate value from the currently bound depth texture. (just take the depth value as-is, no comparison drama πŸ™…β€β™€οΈ)

🌸 GL_TEXTURE_LOD_BIAS 🌸

params specifies a fixed bias value that is to be added to the level-of-detail parameter for the texture before texture sampling. The specified value is added to the shader-supplied bias value (if any) and subsequently clamped into the implementation-defined range -bias max to bias max, where bias max is the value of the implementation defined constant GL_MAX_TEXTURE_LOD_BIAS. The initial value is 0.0. (a little nudge to your LOD, but don't push it too far bestie πŸ’–)

✨ GL_TEXTURE_MIN_FILTER ✨

The texture minifying function is used whenever the level-of-detail function used when sampling from the texture determines that the texture should be minified. There are six defined minifying functions. Two of them use either the nearest texture elements or a weighted average of multiple texture elements to compute the texture value. The other four use mipmaps.

A mipmap is an ordered set of arrays representing the same image at progressively lower resolutions. If the texture has dimensions 2^n Γ— 2^m, there are max(n, m) + 1 mipmaps. The first mipmap is the original texture, with dimensions 2^n Γ— 2^m. Each subsequent mipmap has dimensions 2^(k-1) Γ— 2^(l-1), where 2^k Γ— 2^l are the dimensions of the previous mipmap, until either k = 0 or l = 0. At that point, subsequent mipmaps have dimension 1 Γ— 2^(l-1) or 2^(k-1) Γ— 1 until the final mipmap, which has dimension 1 Γ— 1. To define the mipmaps, call glTexImage1D(), glTexImage2D(), glTexImage3D(), glCopyTexImage1D(), or glCopyTexImage2D() with the level argument indicating the order of the mipmaps. Level 0 is the original texture; level max(n, m) is the final 1 Γ— 1 mipmap. (mipmaps are literally the matryoshka dolls of textures πŸͺ†)

params supplies a function for minifying the texture as one of the following:

  • GL_NEAREST β€” Returns the value of the texture element that is nearest (in Manhattan distance) to the specified texture coordinates. (closest one wins, no blending 🏁)
  • GL_LINEAR β€” Returns the weighted average of the four texture elements that are closest to the specified texture coordinates. These can include items wrapped or repeated from other parts of a texture, depending on the values of GL_TEXTURE_WRAP_S and GL_TEXTURE_WRAP_T, and on the exact mapping. (smooth like butter 🧈)
  • GL_NEAREST_MIPMAP_NEAREST β€” Chooses the mipmap that most closely matches the size of the pixel being textured and uses the GL_NEAREST criterion (the texture element closest to the specified texture coordinates) to produce a texture value. (nearest mipmap + nearest texel = double nearest, extra speedy ⚑)
  • GL_LINEAR_MIPMAP_NEAREST β€” Chooses the mipmap that most closely matches the size of the pixel being textured and uses the GL_LINEAR criterion (a weighted average of the four texture elements that are closest to the specified texture coordinates) to produce a texture value. (nearest mipmap but smooth texels, a classic combo πŸ’…)
  • GL_NEAREST_MIPMAP_LINEAR β€” Chooses the two mipmaps that most closely match the size of the pixel being textured and uses the GL_NEAREST criterion (the texture element closest to the specified texture coordinates) to produce a texture value from each mipmap. The final texture value is a weighted average of those two values. (two mipmaps, nearest texels, then blend the results β€” lowkey fancy ✨)
  • GL_LINEAR_MIPMAP_LINEAR β€” Chooses the two mipmaps that most closely match the size of the pixel being textured and uses the GL_LINEAR criterion (a weighted average of the texture elements that are closest to the specified texture coordinates) to produce a texture value from each mipmap. The final texture value is a weighted average of those two values. (the full smooth experience, aka trilinear filtering, and it ate πŸ”₯)

As more texture elements are sampled in the minification process, fewer aliasing artifacts will be apparent. While the GL_NEAREST and GL_LINEAR minification functions can be faster than the other four, they sample only one or multiple texture elements to determine the texture value of the pixel being rendered and can produce moire patterns or ragged transitions. The initial value of GL_TEXTURE_MIN_FILTER is GL_NEAREST_MIPMAP_LINEAR. (so it's a trade-off: speed vs. pretty. choose wisely bestie 🫢)

πŸ¦‹ GL_TEXTURE_MAG_FILTER πŸ¦‹

The texture magnification function is used whenever the level-of-detail function used when sampling from the texture determines that the texture should be magified. It sets the texture magnification function to either GL_NEAREST or GL_LINEAR (see below). GL_NEAREST is generally faster than GL_LINEAR, but it can produce textured images with sharper edges because the transition between texture elements is not as smooth. The initial value of GL_TEXTURE_MAG_FILTER is GL_LINEAR. (magnification is when you zoom in, and GL_LINEAR is the default because smoothness is usually the vibe 🌈)

  • GL_NEAREST β€” Returns the value of the texture element that is nearest (in Manhattan distance) to the specified texture coordinates. (pixelated realness πŸ‘Ύ)
  • GL_LINEAR β€” Returns the weighted average of the texture elements that are closest to the specified texture coordinates. These can include items wrapped or repeated from other parts of a texture, depending on the values of GL_TEXTURE_WRAP_S and GL_TEXTURE_WRAP_T, and on the exact mapping. (soft and blurry, like a dream ☁️)

πŸ’œ GL_TEXTURE_MIN_LOD πŸ’œ

Sets the minimum level-of-detail parameter. This floating-point value limits the selection of highest resolution mipmap (lowest mipmap level). The initial value is -1000. (a lower bound so you don't go too crisp πŸ“)

⭐ GL_TEXTURE_MAX_LOD ⭐

Sets the maximum level-of-detail parameter. This floating-point value limits the selection of the lowest resolution mipmap (highest mipmap level). The initial value is 1000. (an upper bound so you don't go too blurry πŸŽ€)

πŸ‘‘ GL_TEXTURE_MAX_LEVEL πŸ‘‘

Sets the index of the highest defined mipmap level. This is an integer value. The initial value is 1000. (basically says "this is the smallest mipmap you're allowed to use" β€” keep it iconic πŸ’…)

  • GL_TEXTURE_SWIZZLE_R β€” okay so this sets the swizzle applied to the r component of a texel before it gets returned to the shader. Valid values for param are GL_RED, GL_GREEN, GL_BLUE, GL_ALPHA, GL_ZERO, and GL_ONE. If GL_TEXTURE_SWIZZLE_R is GL_RED, the value for r comes from the first channel of the fetched texel. If it’s GL_GREEN, r comes from the second channel. If it’s GL_BLUE, r comes from the third channel. If it’s GL_ALPHA, r comes from the fourth channel. If it’s GL_ZERO, r gets swapped for 0.0. If it’s GL_ONE, r gets swapped for 1.0. The initial value is GL_RED. πŸ’…
  • GL_TEXTURE_SWIZZLE_G β€” sets the swizzle applied to the g component of a texel before it is returned to the shader. Valid values for param and their effects are similar to those of GL_TEXTURE_SWIZZLE_R. The initial value is GL_GREEN. πŸ“
  • GL_TEXTURE_SWIZZLE_B β€” sets the swizzle applied to the b component of a texel before it is returned to the shader. Valid values for param and their effects are similar to those of GL_TEXTURE_SWIZZLE_R. The initial value is GL_BLUE. πŸ¦‹
  • GL_TEXTURE_SWIZZLE_A β€” sets the swizzle applied to the a component of a texel before it is returned to the shader. Valid values for param and their effects are similar to those of GL_TEXTURE_SWIZZLE_R. The initial value is GL_ALPHA. ✨
  • GL_TEXTURE_SWIZZLE_RGBA β€” sets the swizzles applied to the r, g, b, and a components of a texel before they are returned to the shader. Valid values for params and their effects are similar to those of GL_TEXTURE_SWIZZLE_R, except that all channels are specified simultaneously. Setting the value of GL_TEXTURE_SWIZZLE_RGBA is equivalent (assuming no errors are generated) to setting the parameters of each of GL_TEXTURE_SWIZZLE_R, GL_TEXTURE_SWIZZLE_G, GL_TEXTURE_SWIZZLE_B, and GL_TEXTURE_SWIZZLE_A successively. πŸ‘‘
  • GL_TEXTURE_WRAP_S β€” sets the wrap parameter for texture coordinate s to either GL_CLAMP_TO_EDGE, GL_CLAMP_TO_BORDER, GL_MIRRORED_REPEAT, GL_REPEAT, or GL_MIRROR_CLAMP_TO_EDGE. GL_CLAMP_TO_EDGE causes s coordinates to be clamped to the range 1 2N 1 - 1 2N, where N is the size of the texture in the direction of clamping. GL_CLAMP_TO_BORDER evaluates s coordinates in a similar manner to GL_CLAMP_TO_EDGE. However, in cases where clamping would have occurred in GL_CLAMP_TO_EDGE mode, the fetched texel data is substituted with the values specified by GL_TEXTURE_BORDER_COLOR. GL_REPEAT causes the integer part of the s coordinate to be ignored; the GL uses only the fractional part, thereby creating a repeating pattern. GL_MIRRORED_REPEAT causes the s coordinate to be set to the fractional part of the texture coordinate if the integer part of s is even; if the integer part of s is odd, then the s texture coordinate is set to 1 - frac ⁑ s, where frac ⁑ s represents the fractional part of s. GL_MIRROR_CLAMP_TO_EDGE causes the s coordinate to be repeated as for GL_MIRRORED_REPEAT for one repetition of the texture, at which point the coordinate gets clamped as in GL_CLAMP_TO_EDGE. Initially, GL_TEXTURE_WRAP_S is set to GL_REPEAT. 🌈
  • GL_TEXTURE_WRAP_T β€” sets the wrap parameter for texture coordinate t to either GL_CLAMP_TO_EDGE, GL_CLAMP_TO_BORDER, GL_MIRRORED_REPEAT, GL_REPEAT, or GL_MIRROR_CLAMP_TO_EDGE. See the discussion under GL_TEXTURE_WRAP_S. Initially, GL_TEXTURE_WRAP_T is set to GL_REPEAT. πŸŽ€
  • GL_TEXTURE_WRAP_R β€” sets the wrap parameter for texture coordinate r to either GL_CLAMP_TO_EDGE, GL_CLAMP_TO_BORDER, GL_MIRRORED_REPEAT, GL_REPEAT, or GL_MIRROR_CLAMP_TO_EDGE. See the discussion under GL_TEXTURE_WRAP_S. Initially, GL_TEXTURE_WRAP_R is set to GL_REPEAT. πŸ’œ

πŸ¦‹ NOTES πŸ¦‹

Suppose that a program attempts to sample from a texture and has set GL_TEXTURE_MIN_FILTER to one of the functions that requires a mipmap. If either the dimensions of the texture images currently defined (with previous calls to glTexImage1D(), glTexImage2D(), glTexImage3D(), glCopyTexImage1D(), or glCopyTexImage2D()) do not follow the proper sequence for mipmaps (described above), or there are fewer texture images defined than are needed, or the set of texture images have differing numbers of texture components, then the texture is considered incomplete. 😭

Linear filtering accesses the four nearest texture elements only in 2D textures. In 1D textures, linear filtering accesses the two nearest texture elements. In 3D textures, linear filtering accesses the eight nearest texture elements. πŸ”₯

glTexParameter specifies the texture parameters for the active texture unit, specified by calling glActiveTexture(). glTextureParameter specifies the texture parameters for the texture object with ID texture. 🫢

GL_DEPTH_STENCIL_TEXTURE_MODE is available only if the GL version is 4.3 or greater.

GL_MIRROR_CLAMP_TO_EDGE is available only if the GL version is 4.4 or greater.

πŸ’€ ERRORS πŸ’€

  • GL_INVALID_ENUM is generated by glTexParameter if target is not one of the accepted defined values. πŸ™ˆ
  • GL_INVALID_ENUM is generated if pname is not one of the accepted defined values.
  • GL_INVALID_ENUM is generated if params should have a defined constant value (based on the value of pname) and does not.
  • GL_INVALID_ENUM is generated if glTexParameter{if} or glTextureParameter{if} is called for a non-scalar parameter (pname GL_TEXTURE_BORDER_COLOR or GL_TEXTURE_SWIZZLE_RGBA).
  • GL_INVALID_ENUM is generated if the effective target is either GL_TEXTURE_2D_MULTISAMPLE or GL_TEXTURE_2D_MULTISAMPLE_ARRAY, and pname is any of the sampler states.
  • GL_INVALID_ENUM is generated if the effective target is GL_TEXTURE_RECTANGLE and either of pnames GL_TEXTURE_WRAP_S or GL_TEXTURE_WRAP_T is set to either GL_MIRROR_CLAMP_TO_EDGE, GL_MIRRORED_REPEAT or GL_REPEAT.
  • GL_INVALID_ENUM is generated if the effective target is GL_TEXTURE_RECTANGLE and pname GL_TEXTURE_MIN_FILTER is set to a value other than GL_NEAREST or GL_LINEAR (no mipmap filtering is permitted).
  • GL_INVALID_OPERATION is generated if the effective target is either GL_TEXTURE_2D_MULTISAMPLE or GL_TEXTURE_2D_MULTISAMPLE_ARRAY, and pname GL_TEXTURE_BASE_LEVEL is set to a value other than zero.
  • GL_INVALID_OPERATION is generated by glTextureParameter if texture is not the name of an existing texture object.
  • GL_INVALID_OPERATION is generated if the effective target is GL_TEXTURE_RECTANGLE and pname GL_TEXTURE_BASE_LEVEL is set to any value other than zero.
  • GL_INVALID_VALUE is generated if pname is GL_TEXTURE_BASE_LEVEL or GL_TEXTURE_MAX_LEVEL, and param or params is negative.

πŸŽ€ ASSOCIATED GETS πŸŽ€

glGetTexParameter()

glGetTextureParameter

glGetTexLevelParameter()

glGetTextureLevelParameter

✨ VERSION SUPPORT ✨

Okay bestie, this is the ✨vibe check✨ table β€” every single function and which OpenGL versions actually show up for it. βœ” means she's invited to the party, - means she is not on the guest list. No cap. πŸ’…

The versions, in order: 2.0, 2.1, 3.0, 3.1, 3.2, 3.3, 4.0, 4.1, 4.2, 4.3, 4.4, 4.5.

  • glTexParameterIiv β€” - in 2.0, - in 2.1, then βœ” in 3.0, 3.1, 3.2, 3.3, 4.0, 4.1, 4.2, 4.3, 4.4 and 4.5. She showed up late to the group chat but she's been here ever since 🫢
  • glTexParameterIuiv β€” exact same timeline: - in 2.0, - in 2.1, βœ” from 3.0 all the way through 3.1, 3.2, 3.3, 4.0, 4.1, 4.2, 4.3, 4.4, 4.5.
  • glTexParameterf β€” βœ” in literally all twelve: 2.0, 2.1, 3.0, 3.1, 3.2, 3.3, 4.0, 4.1, 4.2, 4.3, 4.4, 4.5. Day one icon πŸ‘‘
  • glTexParameterfv β€” βœ” in all twelve as well: 2.0, 2.1, 3.0, 3.1, 3.2, 3.3, 4.0, 4.1, 4.2, 4.3, 4.4, 4.5. Slay.
  • glTexParameteri β€” βœ” across the whole board: 2.0, 2.1, 3.0, 3.1, 3.2, 3.3, 4.0, 4.1, 4.2, 4.3, 4.4, 4.5.
  • glTexParameteriv β€” βœ” in every single one too: 2.0, 2.1, 3.0, 3.1, 3.2, 3.3, 4.0, 4.1, 4.2, 4.3, 4.4, 4.5.
  • glTextureParameterIiv β€” - in 2.0, - in 2.1, - in 3.0, - in 3.1, - in 3.2, - in 3.3, - in 4.0, - in 4.1, - in 4.2, - in 4.3, - in 4.4, and finally βœ” in 4.5. She's the new girl and she's main character energy only from 4.5 onward πŸ’€
  • glTextureParameterIuiv β€” same story: - for 2.0, 2.1, 3.0, 3.1, 3.2, 3.3, 4.0, 4.1, 4.2, 4.3, 4.4, and βœ” only at 4.5.
  • glTextureParameterf β€” - in 2.0, 2.1, 3.0, 3.1, 3.2, 3.3, 4.0, 4.1, 4.2, 4.3, 4.4; βœ” in 4.5.
  • glTextureParameterfv β€” - in 2.0, 2.1, 3.0, 3.1, 3.2, 3.3, 4.0, 4.1, 4.2, 4.3, 4.4; βœ” in 4.5.
  • glTextureParameteri β€” - in 2.0, 2.1, 3.0, 3.1, 3.2, 3.3, 4.0, 4.1, 4.2, 4.3, 4.4; βœ” in 4.5.
  • glTextureParameteriv β€” - in 2.0, 2.1, 3.0, 3.1, 3.2, 3.3, 4.0, 4.1, 4.2, 4.3, 4.4; βœ” in 4.5.
So like, the glTextureParameter* girlies are OpenGL 4.5 exclusives. Don't come for them in 3.3, they simply are not there πŸ™ˆ

🌈 SEE ALSO 🌈

Go read these next, they're all in the same friend group:

  • glActiveTexture()
  • glBindTexture()
  • glCopyTexImage1D()
  • glCopyTexImage2D()
  • glCopyTexSubImage1D()
  • glCopyTexSubImage2D()
  • glCopyTexSubImage3D()
  • glPixelStore()
  • glSamplerParameter()
  • glTexImage1D()
  • glTexImage2D()
  • glTexImage3D()
  • glTexSubImage1D()
  • glTexSubImage2D()
  • glTexSubImage3D()

Copyright Β© 1991-2006 Silicon Graphics, Inc. Copyright Β© 2012-2014 Khronos Group. This document is licensed under the SGI Free Software B License. For details, see http://oss.sgi.com/projects/FreeB/.

Copyright Β© 1991-2006 Silicon Graphics, Inc. Copyright Β© 2012-2014 Khronos Group


That's the whole page bestie, you made it to the end πŸ¦‹βœ¨ This one's source is [FIXME: source], version 08/09/2021, and it lives in the manual as GLTEXPARAMETER(3G). Go forth and set those texture parameters, ily, bye πŸ’–

πŸ“¦ where this page comes from