http://bugs.winehq.org/show_bug.cgi?id=17437
--- Comment #107 from hpestilence hpestilence@gmail.com 2009-06-13 00:47:15 --- Created an attachment (id=21767) --> (http://bugs.winehq.org/attachment.cgi?id=21767) atidx10caps + reserved_color_varyings patch
I decided to looking into the varyings again since the fixed catalyst 9.6 release is upon us soon. Looking through the wine logs and source I realized that I tested the test program wrong. I was setting both fragment and vertex shaders to use an array of 12 varyings in order to compile successfully, but I only needed to set 12 in the fragment shader.
So testing again I found out that gl_FrontColor and gl_FrontSecondaryColor are part of the total 64 varyings that can be used. For example, wine is setting an array of varying vec4 IN[15] (-1 for clip varyings) then uses them all and then ends with gl_FrontColor and gl_FrontSecondaryColor which is 17 varyings for ATI.
I fxied it by reserving 2 varyings in the vec4_varyings function and combined it in with the opengl capabilities fixes, but I'll clean it up and submit it without the opengl cap fixes if it looks alright.