Bug 19468 - [965 OGLC] fptex.c test case fails
Summary: [965 OGLC] fptex.c test case fails
Status: RESOLVED FIXED
Alias: None
Product: Mesa
Classification: Unclassified
Component: Drivers/DRI/i965 (show other bugs)
Version: git
Hardware: Other All
: medium normal
Assignee: Ian Romanick
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-01-08 10:34 UTC by Ian Romanick
Modified: 2009-08-24 12:31 UTC (History)
2 users (show)

See Also:
i915 platform:
i915 features:


Attachments
Check the texture coordinate and texture image unit separately. (1.70 KB, patch)
2009-01-13 18:11 UTC, Ian Romanick
Details | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Ian Romanick 2009-01-08 10:34:38 UTC
Test case fptex.c fails.  This test case exercises available texture image units from ARB_fragment_program shaders.  I bisected the failure to the commit below.  I looked at the change, and I don't see anything obviously wrong.  Ugh. :(

commit 4a6ad999ea312f0af85de621c8b6a15a3d3b7ffd
Author: Brian Paul <brianp@vmware.com>
Date:   Thu Jan 1 14:04:57 2009 -0700

    i965: increase number of texture samplers to 16
    
    This lets GLSL shaders use up to 16 samplers.
    Fixed function is still limited to 8 textures.
    Tested with progs/glsl/samplers.c
Comment 1 Brian Paul 2009-01-08 13:02:43 UTC
fptex.c?  I don't see a file by that name in the Mesa tree.
Comment 2 Eric Anholt 2009-01-13 17:25:37 UTC
arbprogparse appears to be clueless about texture image units versus coord units.
Comment 3 Eric Anholt 2009-01-13 17:26:15 UTC
Invalid texture unit index    File - fptex.c, line - 1075.
        !!ARBfp1.0
        OUTPUT out = result.color;
        TEMP textemp1, textemp2;
        TEX  textemp1, fragment.texcoord[7],texture[7], 1D;
        TEX  textemp2, fragment.texcoord[6],texture[8], 1D;
        ADD out, textemp1, textemp2;
        END
Comment 4 Ian Romanick 2009-01-13 18:11:05 UTC
Created attachment 21961 [details] [review]
Check the texture coordinate and texture image unit separately.

Proposed fix.  Check the texture coordinate and texture image unit separately.  I haven't checked to see if nvprogparse.c needs the same treatment.  I haven't tested this yet either.
Comment 5 Brian Paul 2009-01-14 07:31:52 UTC
Ian, I was about to post a patch as well.  Your's and mine look nearly identical.  If it indeed fixes the bug go ahead and commit.
Comment 6 Ian Romanick 2009-01-14 10:10:36 UTC
I verified the proposed fix a couple minutes ago, and everything looks good.  I committed as 2549c26a8b1eec21bdd8f45d3b3dd06e17ac82ae.
Comment 7 Adam Jackson 2009-08-24 12:31:38 UTC
Mass version move, cvs -> git


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.