summaryrefslogtreecommitdiff
path: root/src/mesa/main/texobj.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/main/texobj.c')
-rw-r--r--src/mesa/main/texobj.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/mesa/main/texobj.c b/src/mesa/main/texobj.c
index aaccc03a7c..09fe7b85ba 100644
--- a/src/mesa/main/texobj.c
+++ b/src/mesa/main/texobj.c
@@ -415,7 +415,7 @@ _mesa_test_texobj_completeness( const GLcontext *ctx,
/* Detect cases where the application set the base level to an invalid
* value.
*/
- if ((baseLevel < 0) || (baseLevel > MAX_TEXTURE_LEVELS)) {
+ if ((baseLevel < 0) || (baseLevel >= MAX_TEXTURE_LEVELS)) {
char s[100];
_mesa_sprintf(s, "base level = %d is invalid", baseLevel);
incomplete(t, s);
@@ -940,7 +940,8 @@ _mesa_DeleteTextures( GLsizei n, const GLuint *textures)
/**
* Convert a GL texture target enum such as GL_TEXTURE_2D or GL_TEXTURE_3D
* into the corresponding Mesa texture target index.
- * Return -1 if target is invalid.
+ * Note that proxy targets are not valid here.
+ * \return TEXTURE_x_INDEX or -1 if target is invalid
*/
static GLint
target_enum_to_index(GLenum target)