summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrian <brian.paul@tungstengraphics.com>2007-10-09 14:36:14 -0600
committerBrian <brian.paul@tungstengraphics.com>2007-10-09 14:36:14 -0600
commit31bd01f93b0f5795e290897e79c3f16d90e1f202 (patch)
tree2d029b3a04252526a18002639afbdf115afbff56
parent47ff9428ee09a948e6b412f7e3e46ed1305881a1 (diff)
New ATTRIB interpolation type for vertex program inputs/declarations.
-rwxr-xr-xsrc/mesa/pipe/tgsi/exec/tgsi_build.c2
-rwxr-xr-xsrc/mesa/pipe/tgsi/exec/tgsi_dump.c6
-rw-r--r--src/mesa/pipe/tgsi/exec/tgsi_token.h1
-rw-r--r--src/mesa/pipe/tgsi/mesa/mesa_to_tgsi.c2
4 files changed, 7 insertions, 4 deletions
diff --git a/src/mesa/pipe/tgsi/exec/tgsi_build.c b/src/mesa/pipe/tgsi/exec/tgsi_build.c
index 78f648aae2..56827726f5 100755
--- a/src/mesa/pipe/tgsi/exec/tgsi_build.c
+++ b/src/mesa/pipe/tgsi/exec/tgsi_build.c
@@ -294,7 +294,7 @@ tgsi_build_declaration_interpolation(
{
struct tgsi_declaration_interpolation di;
- assert( interpolate <= TGSI_INTERPOLATE_PERSPECTIVE );
+ assert( interpolate <= TGSI_INTERPOLATE_ATTRIB );
di = tgsi_default_declaration_interpolation();
di.Interpolate = interpolate;
diff --git a/src/mesa/pipe/tgsi/exec/tgsi_dump.c b/src/mesa/pipe/tgsi/exec/tgsi_dump.c
index c179659aee..463f841dde 100755
--- a/src/mesa/pipe/tgsi/exec/tgsi_dump.c
+++ b/src/mesa/pipe/tgsi/exec/tgsi_dump.c
@@ -189,14 +189,16 @@ static const char *TGSI_INTERPOLATES[] =
{
"INTERPOLATE_CONSTANT",
"INTERPOLATE_LINEAR",
- "INTERPOLATE_PERSPECTIVE"
+ "INTERPOLATE_PERSPECTIVE",
+ "INTERPOLATE_ATTRIB"
};
static const char *TGSI_INTERPOLATES_SHORT[] =
{
"CONSTANT",
"LINEAR",
- "PERSPECTIVE"
+ "PERSPECTIVE",
+ "ATTRIB"
};
static const char *TGSI_SEMANTICS[] =
diff --git a/src/mesa/pipe/tgsi/exec/tgsi_token.h b/src/mesa/pipe/tgsi/exec/tgsi_token.h
index 8d5992facb..80c3fcd434 100644
--- a/src/mesa/pipe/tgsi/exec/tgsi_token.h
+++ b/src/mesa/pipe/tgsi/exec/tgsi_token.h
@@ -96,6 +96,7 @@ struct tgsi_declaration_mask
#define TGSI_INTERPOLATE_CONSTANT 0
#define TGSI_INTERPOLATE_LINEAR 1
#define TGSI_INTERPOLATE_PERSPECTIVE 2
+#define TGSI_INTERPOLATE_ATTRIB 3 /**< Vertex shader input attrib */
struct tgsi_declaration_interpolation
{
diff --git a/src/mesa/pipe/tgsi/mesa/mesa_to_tgsi.c b/src/mesa/pipe/tgsi/mesa/mesa_to_tgsi.c
index e4a93cb60d..88de85994a 100644
--- a/src/mesa/pipe/tgsi/mesa/mesa_to_tgsi.c
+++ b/src/mesa/pipe/tgsi/mesa/mesa_to_tgsi.c
@@ -714,7 +714,7 @@ tgsi_mesa_compile_vp_program(
for (i = 0; i < numInputs; i++) {
struct tgsi_full_declaration fulldecl;
fulldecl = make_input_decl(i,
- TGSI_INTERPOLATE_CONSTANT, /* no interp */
+ TGSI_INTERPOLATE_ATTRIB,
TGSI_WRITEMASK_XYZW,
GL_FALSE, inputSemanticName[i],
inputSemanticIndex[i]);