Remove unused texunit parameter to ctx->Driver.GenerateMipmap()
authorBrian <brian.paul@tungstengraphics.com>
Fri, 8 Feb 2008 21:45:58 +0000 (14:45 -0700)
committerDave Airlie <airlied@linux.ie>
Fri, 9 May 2008 03:33:29 +0000 (13:33 +1000)
(cherry picked from commit c3395f4473c8fdf75d04c0dd72e687bc8d8127a7)

src/mesa/main/dd.h
src/mesa/main/fbobject.c
src/mesa/main/mipmap.c
src/mesa/main/mipmap.h
src/mesa/main/texstore.c

index bfbb96aebb77b628068c6be539d4f12a6137fb82..e3ded41acac53edeb4b0fb82604801dceeb198e0 100644 (file)
@@ -330,8 +330,7 @@ struct dd_function_table {
    /**
     * Called by glGenerateMipmap() or when GL_GENERATE_MIPMAP_SGIS is enabled.
     */
-   void (*GenerateMipmap)(GLcontext *ctx,  GLenum target,
-                          const struct gl_texture_unit *texUnit,
+   void (*GenerateMipmap)(GLcontext *ctx, GLenum target,
                           struct gl_texture_object *texObj);
 
    /**
index 6cda7de953f02018113315b8fdeb2c0542a56b9b..1b11828966096c9678617cba82e9481e996e09f3 100644 (file)
@@ -1547,7 +1547,7 @@ _mesa_GenerateMipmapEXT(GLenum target)
 
    /* XXX this might not handle cube maps correctly */
    _mesa_lock_texture(ctx, texObj);
-   ctx->Driver.GenerateMipmap(ctx, target, texUnit, texObj);
+   ctx->Driver.GenerateMipmap(ctx, target, texObj);
    _mesa_unlock_texture(ctx, texObj);
 
    if (ctx->Driver.UnmapTexture)
index 44357fbd6a3b452cfb457a99b1a7872611970ebd..8ca912b3a9d19826997c7b34bb2b4944b2b6e95e 100644 (file)
@@ -934,7 +934,6 @@ make_2d_stack_mipmap(const struct gl_texture_format *format, GLint border,
  */
 void
 _mesa_generate_mipmap(GLcontext *ctx, GLenum target,
-                      const struct gl_texture_unit *texUnit,
                       struct gl_texture_object *texObj)
 {
    const struct gl_texture_image *srcImage;
index df7860328387175bbf6f5d5d08ab1e653cbe31f5..46e16902c8619cf695f5947efbb6aa93900dfa2b 100644 (file)
@@ -30,7 +30,6 @@
 
 extern void
 _mesa_generate_mipmap(GLcontext *ctx, GLenum target,
-                      const struct gl_texture_unit *texUnit,
                       struct gl_texture_object *texObj);
 
 
index 35ef7b1ec116e2558d7f30c518286f4fbd40400d..5363e9e08016011298c74e88004cfb080b552bc9 100644 (file)
@@ -2918,9 +2918,7 @@ _mesa_store_teximage1d(GLcontext *ctx, GLenum target, GLint level,
 
    /* GL_SGIS_generate_mipmap */
    if (level == texObj->BaseLevel && texObj->GenerateMipmap) {
-      ctx->Driver.GenerateMipmap(ctx, target,
-                                 &ctx->Texture.Unit[ctx->Texture.CurrentUnit],
-                                 texObj);
+      ctx->Driver.GenerateMipmap(ctx, target, texObj);
    }
 
    _mesa_unmap_teximage_pbo(ctx, packing);
@@ -3004,9 +3002,7 @@ _mesa_store_teximage2d(GLcontext *ctx, GLenum target, GLint level,
 
    /* GL_SGIS_generate_mipmap */
    if (level == texObj->BaseLevel && texObj->GenerateMipmap) {
-      ctx->Driver.GenerateMipmap(ctx, target,
-                                 &ctx->Texture.Unit[ctx->Texture.CurrentUnit],
-                                 texObj);
+      ctx->Driver.GenerateMipmap(ctx, target, texObj);
    }
 
    _mesa_unmap_teximage_pbo(ctx, packing);
@@ -3080,9 +3076,7 @@ _mesa_store_teximage3d(GLcontext *ctx, GLenum target, GLint level,
 
    /* GL_SGIS_generate_mipmap */
    if (level == texObj->BaseLevel && texObj->GenerateMipmap) {
-      ctx->Driver.GenerateMipmap(ctx, target,
-                                 &ctx->Texture.Unit[ctx->Texture.CurrentUnit],
-                                 texObj);
+      ctx->Driver.GenerateMipmap(ctx, target, texObj);
    }
 
    _mesa_unmap_teximage_pbo(ctx, packing);
@@ -3128,9 +3122,7 @@ _mesa_store_texsubimage1d(GLcontext *ctx, GLenum target, GLint level,
 
    /* GL_SGIS_generate_mipmap */
    if (level == texObj->BaseLevel && texObj->GenerateMipmap) {
-      ctx->Driver.GenerateMipmap(ctx, target,
-                                 &ctx->Texture.Unit[ctx->Texture.CurrentUnit],
-                                 texObj);
+      ctx->Driver.GenerateMipmap(ctx, target, texObj);
    }
 
    _mesa_unmap_teximage_pbo(ctx, packing);
@@ -3183,9 +3175,7 @@ _mesa_store_texsubimage2d(GLcontext *ctx, GLenum target, GLint level,
 
    /* GL_SGIS_generate_mipmap */
    if (level == texObj->BaseLevel && texObj->GenerateMipmap) {
-      ctx->Driver.GenerateMipmap(ctx, target,
-                                 &ctx->Texture.Unit[ctx->Texture.CurrentUnit],
-                                 texObj);
+      ctx->Driver.GenerateMipmap(ctx, target, texObj);
    }
 
    _mesa_unmap_teximage_pbo(ctx, packing);
@@ -3238,9 +3228,7 @@ _mesa_store_texsubimage3d(GLcontext *ctx, GLenum target, GLint level,
 
    /* GL_SGIS_generate_mipmap */
    if (level == texObj->BaseLevel && texObj->GenerateMipmap) {
-      ctx->Driver.GenerateMipmap(ctx, target,
-                                 &ctx->Texture.Unit[ctx->Texture.CurrentUnit],
-                                 texObj);
+      ctx->Driver.GenerateMipmap(ctx, target, texObj);
    }
 
    _mesa_unmap_teximage_pbo(ctx, packing);
@@ -3314,9 +3302,7 @@ _mesa_store_compressed_teximage2d(GLcontext *ctx, GLenum target, GLint level,
 
    /* GL_SGIS_generate_mipmap */
    if (level == texObj->BaseLevel && texObj->GenerateMipmap) {
-      ctx->Driver.GenerateMipmap(ctx, target,
-                                 &ctx->Texture.Unit[ctx->Texture.CurrentUnit],
-                                 texObj);
+      ctx->Driver.GenerateMipmap(ctx, target, texObj);
    }
 
    _mesa_unmap_teximage_pbo(ctx, &ctx->Unpack);
@@ -3426,9 +3412,7 @@ _mesa_store_compressed_texsubimage2d(GLcontext *ctx, GLenum target,
 
    /* GL_SGIS_generate_mipmap */
    if (level == texObj->BaseLevel && texObj->GenerateMipmap) {
-      ctx->Driver.GenerateMipmap(ctx, target,
-                                 &ctx->Texture.Unit[ctx->Texture.CurrentUnit],
-                                 texObj);
+      ctx->Driver.GenerateMipmap(ctx, target, texObj);
    }
 
    _mesa_unmap_teximage_pbo(ctx, &ctx->Unpack);