summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/teximage.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/mesa/main/teximage.c')
-rw-r--r--src/mesa/main/teximage.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/mesa/main/teximage.c b/src/mesa/main/teximage.c
index 9deaab2ad94..fd02a1be23f 100644
--- a/src/mesa/main/teximage.c
+++ b/src/mesa/main/teximage.c
@@ -967,6 +967,9 @@ _mesa_max_texture_levels(struct gl_context *ctx, GLenum target)
ctx->Extensions.EXT_texture_array)
? ctx->Const.MaxTextureLevels : 0;
case GL_TEXTURE_BUFFER:
+ return _mesa_is_desktop_gl(ctx) &&
+ (ctx->Extensions.ARB_texture_buffer_object ||
+ (ctx->Version >= 31)) ? 1 : 0;
case GL_TEXTURE_EXTERNAL_OES:
/* fall-through */
default: