GLGETTEXPARAMETER(3G)
π GLGETTEXPARAMETER (3G) β the one where you ask a texture how it's doing
okay so bestie, welcome to the 3G manual page for glGetTexParameterfv and glGetTexParameteriv π this is the getter half of the texture-parameter duo β glTexParameter sets stuff, this one reads it back, no cap.
β¨ NAME β¨
glGetTexParameterfv, glGetTexParameteriv β return texture parameter values. yeah that's it, they just hand you the values back like a good friend holding your iced coffee π«Ά
π» C SPECIFICATION π»
void glGetTexParameterfv( GLenum target,
GLenum pname,
GLfloat *params )
void glGetTexParameteriv( GLenum target,
GLenum pname,
GLint *params )
πΈ PARAMETERS πΈ
targetβ the symbolic name of the target texture.GL_TEXTURE_1D,GL_TEXTURE_2D, andGL_TEXTURE_3Dare accepted. that's the whole guest list, no plus-ones πpnameβ the symbolic name of a texture parameter. the accepted ones areGL_TEXTURE_MAG_FILTER,GL_TEXTURE_MIN_FILTER,GL_TEXTURE_MIN_LOD,GL_TEXTURE_MAX_LOD,GL_TEXTURE_BASE_LEVEL,GL_TEXTURE_MAX_LEVEL,GL_TEXTURE_WRAP_S,GL_TEXTURE_WRAP_T,GL_TEXTURE_WRAP_R,GL_TEXTURE_BORDER_COLOR,GL_TEXTURE_PRIORITY, andGL_TEXTURE_RESIDENT. yes, all of them. count them. i'll wait πparamsβ returns the texture parameters. this is where the answer goes, so likeβ¦ give it somewhere to live β¨
π DESCRIPTION π
glGetTexParameter returns in params the value or values of the texture parameter specified as pname. target defines the target texture, either GL_TEXTURE_1D, GL_TEXTURE_2D, or GL_TEXTURE_3D to specify one-, two-, or three-dimensional texturing. and here's the key bit β pname accepts the same symbols as glTexParameter, with the same interpretations. same menu, you're just ordering to-go this time π
GL_TEXTURE_MAG_FILTERβ returns the single-valued texture magnification filter, a symbolic constant. the initial value isGL_LINEAR. iconic default, honestly πGL_TEXTURE_MIN_FILTERβ returns the single-valued texture minification filter, a symbolic constant. the initial value isGL_NEAREST_MIPMAP_LINEAR. mipmaps from day one, we love to see it πGL_TEXTURE_MIN_LODβ returns the single-valued texture minimum level-of-detail value. the initial value is β1000. yes, minus one thousand, it's giving "no limits" π¦GL_TEXTURE_MAX_LODβ returns the single-valued texture maximum level-of-detail value. the initial value is 1000.GL_TEXTURE_BASE_LEVELβ returns the single-valued base texture mipmap level. the initial value is 0. the ground floor fr fr πGL_TEXTURE_MAX_LEVELβ returns the single-valued maximum texture mipmap array level. the initial value is 1000.GL_TEXTURE_WRAP_Sβ returns the single-valued wrapping function for texture coordinates, a symbolic constant. the initial value isGL_REPEAT. it goes around, it comes back around π«GL_TEXTURE_WRAP_Tβ returns the single-valued wrapping function for texture coordinatet, a symbolic constant. the initial value isGL_REPEAT.GL_TEXTURE_WRAP_Rβ returns the single-valued wrapping function for texture coordinater, a symbolic constant. the initial value isGL_REPEAT. third axis, same vibe π§GL_TEXTURE_BORDER_COLORβ returns four integer or floating-point numbers that comprise the RGBA color of the texture border. floating-point values are returned in the range [0, 1]. integer values are returned as a linear mapping of the internal floating-point representation such that 1.0 maps to the most positive representable integer and -1.0 maps to the most negative representable integer. the initial value is (0, 0, 0, 0). transparent border, main character energy πGL_TEXTURE_PRIORITYβ returns the residence priority of the target texture (or the named texture bound to it). the initial value is 1. seeglPrioritizeTextures. like a VIP list but for texture memory πGL_TEXTURE_RESIDENTβ returns the residence status of the target texture. if the value returned inparamsisGL_TRUE, the texture is resident in texture memory. seeglAreTexturesResident. it's the "are you even here rn" check π
β οΈ NOTES β οΈ
GL_TEXTURE_PRIORITYandGL_TEXTURE_RESIDENTare available only if the GL version is 1.1 or greater.GL_TEXTURE_3D,GL_TEXTURE_MIN_LOD,GL_TEXTURE_MAX_LOD,GL_TEXTURE_BASE_LEVEL,GL_TEXTURE_MAX_LEVEL, andGL_TEXTURE_WRAP_Rare available only if the GL version is 1.2 or greater. so likeβ¦ check your version first bestie, don't embarrass yourself π
okay listen: if an error is generated, no change is made to the contents of params. nothing. zero. the vibes stay untouched π
π ERRORS π
GL_INVALID_ENUMis generated iftargetorpnameis not an accepted value. wrong name, wrong party, no entry π₯GL_INVALID_OPERATIONis generated ifglGetTexParameteris executed between the execution ofglBeginand the corresponding execution ofglEnd. so do NOT slide into aglBegin/glEndblock with this, that's the forbidden zone π
π SEE ALSO π
glAreTexturesResident(3G)glPrioritizeTextures(3G)glTexParameter(3G)
the squad, the whole squad, periodt π«Ά
alright that's the page π this was the GLGETTEXPARAMETER(3G) page β that (3G) at the bottom is literally just the same name stamped again as the footer, no version number or date attached, so likeβ¦ imagine a cute little signature line that only says its own name. humble. iconic. we stan. β
go read your texture params, bestie, you're gonna slay β¨π π
π¦ where this page comes from
- opensuse-leap 16.0: Mesa-libGL-devel 24.1.7-160000.3.1 Β· MIT
- opensuse-leap 16.0: Mesa-libGL-devel 24.3.3-160000.3.1 Β· MIT
- opensuse-leap 16.0: Mesa-libGL-devel 24.3.3-160000.3.1 Β· MIT
- opensuse-leap 16.0: Mesa-libGL-devel 24.3.3-160000.3.1 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms