diff options
Diffstat (limited to 'mesalib/src/mesa/drivers/common')
-rw-r--r-- | mesalib/src/mesa/drivers/common/meta.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/mesalib/src/mesa/drivers/common/meta.c b/mesalib/src/mesa/drivers/common/meta.c index db49d90ea..7d7113c56 100644 --- a/mesalib/src/mesa/drivers/common/meta.c +++ b/mesalib/src/mesa/drivers/common/meta.c @@ -3010,7 +3010,10 @@ _mesa_meta_GenerateMipmap(struct gl_context *ctx, GLenum target, _mesa_BindFramebufferEXT(GL_FRAMEBUFFER_EXT, mipmap->FBO); - _mesa_TexParameteri(target, GL_GENERATE_MIPMAP, GL_FALSE); + if (ctx->API == API_OPENGL || ctx->API == API_OPENGLES) + _mesa_TexParameteri(target, GL_GENERATE_MIPMAP, GL_FALSE); + else + assert(!genMipmapSave); if (ctx->Extensions.EXT_framebuffer_sRGB) { _mesa_set_enable(ctx, GL_FRAMEBUFFER_SRGB_EXT, GL_FALSE); @@ -3149,7 +3152,8 @@ _mesa_meta_GenerateMipmap(struct gl_context *ctx, GLenum target, _mesa_meta_end(ctx); _mesa_TexParameteri(target, GL_TEXTURE_MAX_LEVEL, maxLevelSave); - _mesa_TexParameteri(target, GL_GENERATE_MIPMAP, genMipmapSave); + if (genMipmapSave) + _mesa_TexParameteri(target, GL_GENERATE_MIPMAP, genMipmapSave); _mesa_BindFramebufferEXT(GL_FRAMEBUFFER_EXT, fboSave); } |