[Piglit] [PATCH 2/2] Verify that built-in shader inputs are read-only.

Chad Versace chad.versace at linux.intel.com
Thu Nov 10 15:47:40 PST 2011


On 11/10/2011 11:38 AM, Paul Berry wrote:
> These tests verify that the following built-in shader input variables
> are read-only:
> 
> For vertex shaders:
> - gl_Color
> - gl_SecondaryColor
> - gl_Normal
> - gl_Vertex
> - gl_MultiTexCoord0
> - gl_MultiTexCoord1
> - gl_MultiTexCoord2
> - gl_MultiTexCoord3
> - gl_MultiTexCoord4
> - gl_MultiTexCoord5
> - gl_MultiTexCoord6
> - gl_MultiTexCoord7
> - gl_FogCoord
> - gl_VertexID (a GLSL 1.30 feature)
> 
> For fragment shaders:
> - gl_FragCoord
> - gl_FrontFacing
> - gl_ClipDistance (a GLSL 1.30 feature)
> ---
>  .../storage-qualfiers/static-write-color.vert      |   22 ++++++++++++++++++++
>  .../storage-qualfiers/static-write-fog-coord.vert  |   22 ++++++++++++++++++++
>  .../storage-qualfiers/static-write-frag-coord.frag |   14 ++++++++++++
>  .../static-write-front-facing.frag                 |   14 ++++++++++++
>  .../static-write-multitexcoord0.vert               |   22 ++++++++++++++++++++
>  .../static-write-multitexcoord1.vert               |   22 ++++++++++++++++++++
>  .../static-write-multitexcoord2.vert               |   22 ++++++++++++++++++++
>  .../static-write-multitexcoord3.vert               |   22 ++++++++++++++++++++
>  .../static-write-multitexcoord4.vert               |   22 ++++++++++++++++++++
>  .../static-write-multitexcoord5.vert               |   22 ++++++++++++++++++++
>  .../static-write-multitexcoord6.vert               |   22 ++++++++++++++++++++
>  .../static-write-multitexcoord7.vert               |   22 ++++++++++++++++++++
>  .../storage-qualfiers/static-write-normal.vert     |   22 ++++++++++++++++++++
>  .../static-write-secondary-color.vert              |   22 ++++++++++++++++++++
>  .../storage-qualfiers/static-write-vertex.vert     |   22 ++++++++++++++++++++
>  .../static-write-clip-distance.frag                |   20 ++++++++++++++++++
>  .../storage-qualifiers/static-write-in-direct.vert |   18 ++++++++++++++++
>  .../static-write-in-indirect.vert                  |   21 +++++++++++++++++++
>  .../storage-qualifiers/static-write-vertex-id.vert |   20 ++++++++++++++++++

All the tests look good, but I have two comments.

Along with gl_Color and gl_SecondaryColor, we should test gl_BackColor and gl_BackSecondaryColor too.

Tests static-write-in-indirect and static-write-in-direct fall outside of the commit's subject. The commit
message should be updated to mention them or they should be placed in a separate patch.

----
Chad Versace
chad.versace at linux.intel.com


More information about the Piglit mailing list