With an old driver version of Nvidia, whenever I try to set
gl3.glTexParameteri(GL3.GL_TEXTURE_RECTANGLE, GL3.GL_TEXTURE_MAX_LEVEL, 0);
I get the gl error GL_INVALID_OPERATION 1282…
Looking at the man page
-
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.
I and II case have nothing to do since my target is GL_TEXTURE_RECTANGLE and I am using glTexParameteri instead of glTextureParameter.
III case is interesting, but I do set the GL_TEXTURE_BASE_LEVEL to 0 just before, as following:
gl3.glTexParameteri(GL3.GL_TEXTURE_RECTANGLE, GL3.GL_TEXTURE_BASE_LEVEL, 0);
gl3.glTexParameteri(GL3.GL_TEXTURE_RECTANGLE, GL3.GL_TEXTURE_MAX_LEVEL, 0);
So neither in this case I should get the GL_INVALID_OPERATION, but I do…
why?