GLINVALIDATETEXSUBIM(3G)
Hey bestie π you just opened GLINVALIDATETEXSUBIM(3G) β the manual page for glInvalidateTexSubImage β and we are gonna make texture-region invalidation make sense, no cap.
β¨ NAME β¨
glInvalidateTexSubImage β invalidate a region of a texture image. Iconic behavior, honestly. π¦
π C SPECIFICATION π
void glInvalidateTexSubImage(GLuint texture, GLint level, GLint xoffset,
GLint yoffset, GLint zoffset,
GLsizei width, GLsizei height,
GLsizei depth);
π PARAMETERS π
textureβ the name of a texture object, and you're invalidating a subregion of it. Name the texture, bestie.levelβ the level of detail of the texture object where the region lives.xoffsetβ the X offset of the region you're invalidating.yoffsetβ the Y offset of the region you're invalidating.zoffsetβ the Z offset of the region you're invalidating.widthβ the width of the region you're invalidating.heightβ the height of the region you're invalidating.depthβ the depth of the region you're invalidating.
π¦ DESCRIPTION π¦
Okay so glInvalidateTexSubImage invalidates all or part of a texture image. texture and level indicate which texture image is being invalidated. After this command, the data in that subregion have undefined values β yes, undefined, that's the whole vibe. π
xoffset, yoffset, zoffset, width, height, and depth are interpreted as they are in glTexSubImage3D(). For texture targets that don't have certain dimensions, this command treats those dimensions as having a size of 1. For example, to invalidate a portion of a two-dimensional texture, the application would use zoffset equal to zero and depth equal to one. Little dimension hack, love that for us. β¨
Cube map textures are treated as an array of six slices in the z-dimension, where a value of zoffset is interpreted as specifying face GL_TEXTURE_CUBE_MAP_POSITIVE_X + zoffset. Six slices, cube-map main character energy. π§
level must be greater than or equal to zero and be less than the base 2 logarithm of the maximum texture width, height, or depth. xoffset, yoffset and zoffset must be greater than or equal to zero and be less than the width, height or depth of the image, respectively. Furthermore, xoffset + width, yoffset + height, and zoffset + depth must be less than or equal to the width, height or depth of the image, respectively. Math check, bestie β don't skip it. π
For textures of targets GL_TEXTURE_RECTANGLE, GL_TEXTURE_BUFFER, GL_TEXTURE_2D_MULTISAMPLE, or GL_TEXTURE_2D_MULTISAMPLE_ARRAY, level must be zero. Zero. Not one, not two. Zero. π
π ERRORS π
GL_INVALID_VALUEis generated ifxoffset,yoffsetorzoffsetis less than zero, or if any of them is greater than the size of the image in the corresponding dimension.GL_INVALID_VALUEis generated iflevelis less than zero or if it is greater or equal to the base 2 logarithm of the maximum texture width, height, or depth.GL_INVALID_VALUEis generated if the target oftextureis any ofGL_TEXTURE_RECTANGLE,GL_TEXTURE_BUFFER,GL_TEXTURE_2D_MULTISAMPLE, orGL_TEXTURE_2D_MULTISAMPLE_ARRAYandlevelis not zero.GL_INVALID_VALUEis generated iftextureis not the name of an existing texture object.
No cap, these are the exact error conditions. Read them before you come crying to the group chat. π«Ά
π₯ ASSOCIATED GETS π₯
glGet() with argument GL_MAX_TEXTURE_SIZE. That's the get, bestie. β
π VERSION SUPPORT π
OpenGL Version check, with Function / Feature Name: glInvalidateTexSubImage.
2.0:-2.1:-3.0:-3.1:-3.2:-3.3:-4.0:-4.1:-4.2:-4.3:β4.4:β4.5:β
So it's giving 4.3 and up, and that's periodt. πΈ
π SEE ALSO π
Go peek at these too, iykyk:
glInvalidateTexImage(),,glInvalidateBufferSubData()glInvalidateBufferData()glInvalidateFramebuffer()glInvalidateSubFramebuffer()
π COPYRIGHT π
Copyright Β© 2013-2014 Khronos Group. This material may be distributed subject to the terms and conditions set forth in the Open Publication License, v 1.0, 8 June 1999. http://opencontent.org/openpub/.
π COPYRIGHT (the sequel) π
Copyright Β© 2013-2014 Khronos Group
Signing off with the footer vibe, bestie: source/version is [FIXME: source], the date is 08/09/2021, and that's the whole GLINVALIDATETEXSUBIM(3G) moment. Bye bestie, go invalidate responsibly! π«Άβ¨
π¦ where this page comes from
- centos-stream 9: gl-manpages 1.1-24.20190306.el9 Β· MIT and Open Publication
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms