Mesa (master): st/mesa: remove unused needFlush parameter to st_finalize_texture()

Brian Paul brianp at kemper.freedesktop.org
Mon May 3 23:14:27 UTC 2010


Module: Mesa
Branch: master
Commit: 295a87f6c211322faefc4ef7f88f02722973f5b6
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=295a87f6c211322faefc4ef7f88f02722973f5b6

Author: Brian Paul <brianp at vmware.com>
Date:   Mon May  3 16:13:20 2010 -0600

st/mesa: remove unused needFlush parameter to st_finalize_texture()

---

 src/mesa/state_tracker/st_atom_texture.c |    8 ++++----
 src/mesa/state_tracker/st_cb_texture.c   |    6 +-----
 src/mesa/state_tracker/st_cb_texture.h   |    3 +--
 src/mesa/state_tracker/st_gen_mipmap.c   |    3 +--
 4 files changed, 7 insertions(+), 13 deletions(-)

diff --git a/src/mesa/state_tracker/st_atom_texture.c b/src/mesa/state_tracker/st_atom_texture.c
index 2575add..217116e 100644
--- a/src/mesa/state_tracker/st_atom_texture.c
+++ b/src/mesa/state_tracker/st_atom_texture.c
@@ -62,7 +62,7 @@ update_textures(struct st_context *st)
       if (samplersUsed & (1 << su)) {
          struct gl_texture_object *texObj;
          struct st_texture_object *stObj;
-         GLboolean flush, retval;
+         GLboolean retval;
          GLuint texUnit;
 
          if (fprog->Base.SamplersUsed & (1 << su))
@@ -77,7 +77,7 @@ update_textures(struct st_context *st)
          }
          stObj = st_texture_object(texObj);
 
-         retval = st_finalize_texture(st->ctx, st->pipe, texObj, &flush);
+         retval = st_finalize_texture(st->ctx, st->pipe, texObj);
          if (!retval) {
             /* out of mem */
             continue;
@@ -140,9 +140,9 @@ finalize_textures(struct st_context *st)
             = st->ctx->Texture.Unit[texUnit]._Current;
 
          if (texObj) {
-            GLboolean flush, retval;
+            GLboolean retval;
 
-            retval = st_finalize_texture(st->ctx, st->pipe, texObj, &flush);
+            retval = st_finalize_texture(st->ctx, st->pipe, texObj);
             if (!retval) {
                /* out of mem */
                st->missing_textures = GL_TRUE;
diff --git a/src/mesa/state_tracker/st_cb_texture.c b/src/mesa/state_tracker/st_cb_texture.c
index 5021dcb..ed8eb29 100644
--- a/src/mesa/state_tracker/st_cb_texture.c
+++ b/src/mesa/state_tracker/st_cb_texture.c
@@ -1812,8 +1812,7 @@ copy_image_data_to_texture(struct st_context *st,
 GLboolean
 st_finalize_texture(GLcontext *ctx,
 		    struct pipe_context *pipe,
-		    struct gl_texture_object *tObj,
-		    GLboolean *needFlush)
+		    struct gl_texture_object *tObj)
 {
    struct st_context *st = st_context(ctx);
    struct st_texture_object *stObj = st_texture_object(tObj);
@@ -1822,8 +1821,6 @@ st_finalize_texture(GLcontext *ctx,
    struct st_texture_image *firstImage;
    enum pipe_format firstImageFormat;
 
-   *needFlush = GL_FALSE;
-
    if (stObj->base._Complete) {
       /* The texture is complete and we know exactly how many mipmap levels
        * are present/needed.  This is conditional because we may be called
@@ -1908,7 +1905,6 @@ st_finalize_texture(GLcontext *ctx,
           */
          if (stImage && stObj->pt != stImage->pt) {
             copy_image_data_to_texture(st, stObj, level, stImage);
-	    *needFlush = GL_TRUE;
          }
       }
    }
diff --git a/src/mesa/state_tracker/st_cb_texture.h b/src/mesa/state_tracker/st_cb_texture.h
index f1fe033..1cd9fc3 100644
--- a/src/mesa/state_tracker/st_cb_texture.h
+++ b/src/mesa/state_tracker/st_cb_texture.h
@@ -33,8 +33,7 @@
 extern GLboolean
 st_finalize_texture(GLcontext *ctx,
 		    struct pipe_context *pipe, 
-		    struct gl_texture_object *tObj,
-		    GLboolean *needFlush);
+		    struct gl_texture_object *tObj);
 
 
 extern struct gl_texture_object *
diff --git a/src/mesa/state_tracker/st_gen_mipmap.c b/src/mesa/state_tracker/st_gen_mipmap.c
index a015c4b..6b1d51b 100644
--- a/src/mesa/state_tracker/st_gen_mipmap.c
+++ b/src/mesa/state_tracker/st_gen_mipmap.c
@@ -311,7 +311,6 @@ st_generate_mipmap(GLcontext *ctx, GLenum target,
        * mipmap levels we need to generate.  So allocate a new texture.
        */
       struct pipe_resource *oldTex = stObj->pt;
-      GLboolean needFlush;
 
       /* create new texture with space for more levels */
       stObj->pt = st_texture_create(st,
@@ -331,7 +330,7 @@ st_generate_mipmap(GLcontext *ctx, GLenum target,
       /* This will copy the old texture's base image into the new texture
        * which we just allocated.
        */
-      st_finalize_texture(ctx, st->pipe, texObj, &needFlush);
+      st_finalize_texture(ctx, st->pipe, texObj);
 
       /* release the old tex (will likely be freed too) */
       pipe_resource_reference(&oldTex, NULL);




More information about the mesa-commit mailing list