diff options
author | Brian <brian.paul@tungstengraphics.com> | 2007-09-20 14:47:22 -0600 |
---|---|---|
committer | Brian <brian.paul@tungstengraphics.com> | 2007-09-20 14:47:22 -0600 |
commit | f69b5c56feb60791bad27d491ee9592238d4efb0 (patch) | |
tree | 4e20d2ee723239121e5bf8b94a9786dc05e00440 /src/mesa/pipe/tgsi/exec | |
parent | 478d1e2c9c73fc29542375c44d01ab964ce8eccf (diff) |
Clean-up the TGSI_SEMANTIC tokens, introduce semantic indexes.
Still need to produce decl instructions for vertex shaders...
Diffstat (limited to 'src/mesa/pipe/tgsi/exec')
-rwxr-xr-x | src/mesa/pipe/tgsi/exec/tgsi_build.c | 2 | ||||
-rwxr-xr-x | src/mesa/pipe/tgsi/exec/tgsi_dump.c | 22 | ||||
-rw-r--r-- | src/mesa/pipe/tgsi/exec/tgsi_token.h | 24 |
3 files changed, 16 insertions, 32 deletions
diff --git a/src/mesa/pipe/tgsi/exec/tgsi_build.c b/src/mesa/pipe/tgsi/exec/tgsi_build.c index 1320872c64..78f648aae2 100755 --- a/src/mesa/pipe/tgsi/exec/tgsi_build.c +++ b/src/mesa/pipe/tgsi/exec/tgsi_build.c @@ -309,7 +309,7 @@ tgsi_default_declaration_semantic( void ) { struct tgsi_declaration_semantic ds; - ds.SemanticName = TGSI_SEMANTIC_DEPTH; + ds.SemanticName = TGSI_SEMANTIC_POSITION; ds.SemanticIndex = 0; ds.Padding = 0; diff --git a/src/mesa/pipe/tgsi/exec/tgsi_dump.c b/src/mesa/pipe/tgsi/exec/tgsi_dump.c index 0a47ad2a8c..315354198a 100755 --- a/src/mesa/pipe/tgsi/exec/tgsi_dump.c +++ b/src/mesa/pipe/tgsi/exec/tgsi_dump.c @@ -201,28 +201,22 @@ static const char *TGSI_INTERPOLATES_SHORT[] = static const char *TGSI_SEMANTICS[] = { - "SEMANTIC_DEPTH", - "SEMANTIC_COLOR0", - "SEMANTIC_COLOR1", - "SEMANTIC_COLOR0B", - "SEMANTIC_COLOR1B", "SEMANTIC_POSITION", + "SEMANTIC_COLOR", + "SEMANTIC_BCOLOR", "SEMANTIC_FOG", - "SEMANTIC_OTHER," - "SEMANTIC_TEX0", + "SEMANTIC_TEXCOORD", + "SEMANTIC_GENERIC," }; static const char *TGSI_SEMANTICS_SHORT[] = { - "DEPTH", - "COLOR0", - "COLOR1", - "COLOR0B", - "COLOR1B", "POSITION", + "COLOR", + "BCOLOR", "FOG", - "OTHER", - "TEX0" + "TEXCOORD", + "GENERIC", }; static const char *TGSI_IMMS[] = diff --git a/src/mesa/pipe/tgsi/exec/tgsi_token.h b/src/mesa/pipe/tgsi/exec/tgsi_token.h index a642ba131a..2d468b801e 100644 --- a/src/mesa/pipe/tgsi/exec/tgsi_token.h +++ b/src/mesa/pipe/tgsi/exec/tgsi_token.h @@ -103,23 +103,13 @@ struct tgsi_declaration_interpolation unsigned Padding : 28; }; -#define TGSI_SEMANTIC_DEPTH 0 -#define TGSI_SEMANTIC_COLOR0 1 -#define TGSI_SEMANTIC_COLOR1 2 -#define TGSI_SEMANTIC_COLOR0B 3 /**< back-face primary color */ -#define TGSI_SEMANTIC_COLOR1B 4 /**< back-face secondary color */ -#define TGSI_SEMANTIC_POSITION 5 -#define TGSI_SEMANTIC_FOG 6 -#define TGSI_SEMANTIC_OTHER 7 /* XXX temp */ -#define TGSI_SEMANTIC_TEX0 8 -#define TGSI_SEMANTIC_TEX1 9 -#define TGSI_SEMANTIC_TEX2 10 -#define TGSI_SEMANTIC_TEX3 11 -#define TGSI_SEMANTIC_TEX4 12 -#define TGSI_SEMANTIC_TEX5 13 -#define TGSI_SEMANTIC_TEX6 14 -#define TGSI_SEMANTIC_TEX7 15 -#define TGSI_SEMANTIC_COUNT 16 /**< number of semantic values */ +#define TGSI_SEMANTIC_POSITION 0 +#define TGSI_SEMANTIC_COLOR 1 +#define TGSI_SEMANTIC_BCOLOR 2 /**< back-face color */ +#define TGSI_SEMANTIC_FOG 3 +#define TGSI_SEMANTIC_TEXCOORD 4 +#define TGSI_SEMANTIC_GENERIC 5 +#define TGSI_SEMANTIC_COUNT 6 /**< number of semantic values */ struct tgsi_declaration_semantic { |