Roland Scheidegger wrote:

Here are the cleaned-up texrect fixes - last time there was still some disagreement about how some things should be fixed.
If there are no objections I'm just going to try out my newly aquired super-powers and commit it ;-).

Nervous about your first commit? :) With the exception of one minor suggestion (below), the patch looks good to me.


Index: src/mesa/main/texobj.c
===================================================================
RCS file: /cvs/mesa/Mesa/src/mesa/main/texobj.c,v
retrieving revision 1.81
diff -u -r1.81 texobj.c
--- src/mesa/main/texobj.c      27 Jan 2004 16:34:46 -0000      1.81
+++ src/mesa/main/texobj.c      5 Feb 2004 00:03:38 -0000
@@ -818,7 +818,16 @@
             newTexObj->WrapT = GL_CLAMP_TO_EDGE;
             newTexObj->WrapR = GL_CLAMP_TO_EDGE;
             newTexObj->MinFilter = GL_LINEAR;
-         }
+            if (ctx->Driver.TexParameter) {
+               GLfloat fparam[1];
+               fparam[0] = (GLfloat) GL_CLAMP_TO_EDGE;

I'd make this 'static const GLfloat fparam[1] = (GLfloat) GL_CLAMP_TO_EDGE;'


+               (*ctx->Driver.TexParameter)( ctx, target, newTexObj, 
GL_TEXTURE_WRAP_S, fparam );
+               (*ctx->Driver.TexParameter)( ctx, target, newTexObj, 
GL_TEXTURE_WRAP_T, fparam );
+               (*ctx->Driver.TexParameter)( ctx, target, newTexObj, 
GL_TEXTURE_WRAP_R, fparam );
+               fparam[0] = (GLfloat) GL_LINEAR;
+               (*ctx->Driver.TexParameter)( ctx, target, newTexObj, 
GL_TEXTURE_MIN_FILTER, fparam );
+            }
+          }
       }
       else {
          /* if this is a new texture id, allocate a texture object now */




-------------------------------------------------------
The SF.Net email is sponsored by EclipseCon 2004
Premiere Conference on Open Tools Development and Integration
See the breadth of Eclipse activity. February 3-5 in Anaheim, CA.
http://www.eclipsecon.org/osdn
--
_______________________________________________
Dri-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/dri-devel

Reply via email to