Module: Mesa
Branch: master
Commit: 07a30e3d18a528a2dc8a247af5c43e7428be1743
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=07a30e3d18a528a2dc8a247af5c43e7428be1743

Author: Dave Airlie <airl...@redhat.com>
Date:   Thu Oct 14 14:40:24 2010 +1000

tgsi: add scanner support for centroid inputs

---

 src/gallium/auxiliary/tgsi/tgsi_scan.c |    1 +
 src/gallium/auxiliary/tgsi/tgsi_scan.h |    1 +
 2 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/gallium/auxiliary/tgsi/tgsi_scan.c 
b/src/gallium/auxiliary/tgsi/tgsi_scan.c
index 5382748..6585da3 100644
--- a/src/gallium/auxiliary/tgsi/tgsi_scan.c
+++ b/src/gallium/auxiliary/tgsi/tgsi_scan.c
@@ -147,6 +147,7 @@ tgsi_scan_shader(const struct tgsi_token *tokens,
                   info->input_semantic_name[reg] = 
(ubyte)fulldecl->Semantic.Name;
                   info->input_semantic_index[reg] = 
(ubyte)fulldecl->Semantic.Index;
                   info->input_interpolate[reg] = 
(ubyte)fulldecl->Declaration.Interpolate;
+                  info->input_centroid[reg] = 
(ubyte)fulldecl->Declaration.Centroid;
                   info->input_cylindrical_wrap[reg] = 
(ubyte)fulldecl->Declaration.CylindricalWrap;
                   info->num_inputs++;
                }
diff --git a/src/gallium/auxiliary/tgsi/tgsi_scan.h 
b/src/gallium/auxiliary/tgsi/tgsi_scan.h
index 374c7ed..104097f 100644
--- a/src/gallium/auxiliary/tgsi/tgsi_scan.h
+++ b/src/gallium/auxiliary/tgsi/tgsi_scan.h
@@ -45,6 +45,7 @@ struct tgsi_shader_info
    ubyte input_semantic_name[PIPE_MAX_SHADER_INPUTS]; /**< TGSI_SEMANTIC_x */
    ubyte input_semantic_index[PIPE_MAX_SHADER_INPUTS];
    ubyte input_interpolate[PIPE_MAX_SHADER_INPUTS];
+   ubyte input_centroid[PIPE_MAX_SHADER_INPUTS];
    ubyte input_usage_mask[PIPE_MAX_SHADER_INPUTS];
    ubyte input_cylindrical_wrap[PIPE_MAX_SHADER_INPUTS];
    ubyte output_semantic_name[PIPE_MAX_SHADER_OUTPUTS]; /**< TGSI_SEMANTIC_x */

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to