Roland Scheidegger wrote:
(since the original email never made it to the list, a new one - it's not a resend though)

texrect is broken here (and I've no idea why it works for other people ;-)).
There are 2 problems in the driver which cause this:
First, if glGenTextures is called, there is no texture target yet. This will cause the r200 driver (in r200AllocTexObj) to initialize the texture min filter to GL_NEAREST_MIPMAP_LINEAR. The problem is when the texture object is now bound to a RECTANGLE_NV target, the min filter will not change, causing havoc (the also illegal clamp mode doesn't seem to hurt much).
Second problem is the r200TexParameter, it will only do anything for 1D and 2D targets - thus, even if an application explicitly sets a different texture filter, the hardware will still try to use mipmapping for rectangle targets. Removing the target condition will fix this (why is it there? Mesa already should have checked illegal combinations, or are there some OGL compliant target/param combinations which are not supported in hardware?)
Both problems are also present in the radeon driver, but texrect seems to work there nonetheless...


attached a quick patch (only for r200, and I doubt it will attach cleanly, but I guess it's too ugly anyway).




@@ -888,9 +1070,9 @@
               _mesa_lookup_enum_by_nr( pname ) );
    }

-   if ( ( target != GL_TEXTURE_2D ) &&
+/*   if ( ( target != GL_TEXTURE_2D ) &&
        ( target != GL_TEXTURE_1D ) )
-      return;
+      return;*/

Wouldn't this change be enough on its own? This test is broken & has probably been causing subtle problems for ages.


Keith




------------------------------------------------------- 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