mesa: update fragResults array in arb_output_attrib_string()
authorBrian Paul <brianp@vmware.com>
Fri, 27 Feb 2009 20:44:42 +0000 (13:44 -0700)
committerBrian Paul <brianp@vmware.com>
Fri, 27 Feb 2009 20:45:49 +0000 (13:45 -0700)
Plus add some comments.

src/mesa/shader/prog_print.c

index 80be51c3c577c55e262e6a560fc79da1c8d44e62..2747480834eb5f8bf9938b036963340a3435a66f 100644 (file)
@@ -86,6 +86,9 @@ file_string(enum register_file f, gl_prog_print_mode mode)
 static const char *
 arb_input_attrib_string(GLint index, GLenum progType)
 {
+   /*
+    * These strings should match the VERT_ATTRIB_x and FRAG_ATTRIB_x tokens.
+    */
    const char *vertAttribs[] = {
       "vertex.position",
       "vertex.weight",
@@ -160,6 +163,9 @@ arb_input_attrib_string(GLint index, GLenum progType)
 static const char *
 arb_output_attrib_string(GLint index, GLenum progType)
 {
+   /*
+    * These strings should match the VERT_RESULT_x and FRAG_RESULT_x tokens.
+    */
    const char *vertResults[] = {
       "result.position",
       "result.color.primary",
@@ -184,7 +190,12 @@ arb_output_attrib_string(GLint index, GLenum progType)
    };
    const char *fragResults[] = {
       "result.color",
-      "result.depth"
+      "result.color(half)",
+      "result.depth",
+      "result.color[0]",
+      "result.color[1]",
+      "result.color[2]",
+      "result.color[3]"
    };
 
    if (progType == GL_VERTEX_PROGRAM_ARB) {